ThinkChat2.0新版上线,更智能更精彩,支持会话、画图、阅读、搜索等,送10W Token,即刻开启你的AI之旅 广告
# 字典 map * 与集合类似,也是储存唯一值的数据结构,但是以key/value的形式 * 字典的常用操作:健值对的增删查改 * map和对象的区别: * 在js中map和对象是非常像的,都是采用键值对的数据结构。 * 它们不同点是它们的key值。对象的key值只允许是字符串,而map的key值可以是字符串、数字、对象等各种类型。 ![](https://img.kancloud.cn/45/4b/454b03e387797a39c4a4d8989a57fd13_509x173.png) [无重复字符的最长子串]([https://leetcode-cn.com/problems/longest-substring-without-repeating-characters/](https://leetcode-cn.com/problems/longest-substring-without-repeating-characters/)) ![](https://img.kancloud.cn/c8/93/c8939474a09709a24f9505c145d28bb5_778x453.png) [最小覆盖子串](https://leetcode-cn.com/problems/minimum-window-substring/) ![](https://img.kancloud.cn/97/a3/97a3deeb1263681c573fcd0919ece63b_846x262.png) ![](https://img.kancloud.cn/e2/ec/e2ecc37433bfa602aab5b86241cef8c6_1034x814.png)