![](https://img-blog.csdnimg.cn/20201014180756724.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
java集合
小炫剑指大厂
主要为应届生提供校招或者实习的经验,以及技术博文。
欢迎关注公众号:小炫剑指大厂
展开
-
Java集合(一)ArrayList源码分析
我是看一篇博客,并且在它的基础上面增加内容的。 地址为https://www.cnblogs.com/xujian2014/p/4625346.html 看源码之前要先了解一些知识 @SuppressWarnings("unchecked") 告诉编译器忽略 unchecked 警告信息 System.arrayCopy的源代码声明 : public static void arra...原创 2019-06-09 19:37:32 · 1557 阅读 · 0 评论 -
java集合(二)HashMap 的长度为什么是2的幂次方
先看下源码 /** * Returns a power of two size for the given target capacity. */ static final int tableSizeFor(int cap) { int n = cap - 1; n |= n >>> 1; n |=...原创 2019-06-10 16:36:14 · 2719 阅读 · 0 评论