摘要: Given a string which consists of lowercase or uppercase letters, find the length of the longest palindromes that can be built with those letters. This 阅读全文
posted @ 2017-01-07 20:26 sunli0205 阅读(176) 评论(0) 推荐(0) 编辑
摘要: HashSet 1.底层数据结构是哈希表。 2.哈希表依赖两个方法: hashCode()和equals() 执行顺序: 首先判断hashCode()值是否相同 相同:继续执行equals(),看其返回值 返回true:说明元素重复,不添加 返回false:说明不重复,就直接添加到集合 不相同:就直 阅读全文
posted @ 2017-01-07 20:13 sunli0205 阅读(174) 评论(0) 推荐(0) 编辑