JAVA
sophia_tone2w
这个作者很懒,什么都没留下…
展开
-
JAVA--Iterator
转载~~侵删 迭代器(Iterator) 迭代器是一种设计模式,它是一个对象,它可以遍历并选择序列中的对象,而开发人员不需要了解该序列的底层结构。迭代器通常被称为“轻量级”对象,因为创建它的代价小。 Java中的Iterator功能比较简单,并且只能单向移动: (1) 使用方法iterator()要求容器返回一个Iterator。第一次调用Iterator的ne转载 2016-06-09 00:02:41 · 194 阅读 · 0 评论 -
LeetCode--No.349--Intersection of Two Arrays2
Given two arrays, write a function to compute their intersection. Example: Given nums1 = [1, 2, 2, 1], nums2 = [2, 2], return [2]. Note: Each element in the result must be unique. T原创 2016-06-09 00:08:02 · 297 阅读 · 0 评论 -
JAVA--IO
主要转自:http://lapulande.iteye.com/blog/706051 其他认为很有价值的讲解IO的blog: http://blog.csdn.net/yczz/article/details/38761237 http://blog.csdn.net/zhangerqing/article/details/8466532 先给出一个简单的java的io例子。 改转载 2016-06-10 00:00:52 · 193 阅读 · 0 评论 -
LeetCode--No.13--Roman to Integer
Given a roman numeral, convert it to an integer. Input is guaranteed to be within the range from 1 to 3999. 这道easy也是费了好大尽。 出错的地方如下: 1. Map,尖括号里的数据类型需要使用引用类型。 原始类型 封装类 boolean原创 2016-06-14 01:41:50 · 225 阅读 · 0 评论 -
String && StringBuffer && StringBuilder
转载自: 黑色幽默Lion http://www.cnblogs.com/pepcod/archive/2013/02/16/2913557.html JAVA中用于处理字符串常用的有三个类: java.lang.String、 java.lang.StringBuffer、 java.lang.StringBuilder, 这三者的共同之处都是 f转载 2016-06-14 23:35:22 · 183 阅读 · 0 评论