摘要:
点进ThreadPoolExectutor源码ThreadPoolExecutor.java可以看到线程池的核心实现; ThreadPoolExecutor 首先是ThreadPoolExecutor()里面可以看到线程池核心参数 public ThreadPoolExecutor(int core 阅读全文
posted @ 2025-11-26 22:31
go__Ahead
阅读(100)
评论(0)
推荐(0)
摘要:
链接直达 分析 字母异位分词sort一下就是一样的,可以当作key 还是hash,只不过value是List,key是排序后的string。 所以直接遍历字符数组,插入到map[sort(str)]中去 然后再遍历map,将每个value加到结果中去 代码 class Solution { publ 阅读全文
posted @ 2025-11-26 14:23
go__Ahead
阅读(4)
评论(0)
推荐(0)
摘要:
链接直达:1-两数之和 分析: 梦(maybe噩梦)开始的地方! 这个题在哈希,应该是将数组和下标存储在unordered_map中,使用hash的find(), 常规想法可能是先创建unordered_map,然后再遍历数组,使用find(), 但是呢,我们可以一边遍历,一边查找,没找到再插入{n 阅读全文
posted @ 2025-11-26 14:16
go__Ahead
阅读(1)
评论(0)
推荐(0)

浙公网安备 33010602011771号