码迷,mamicode.com
首页 >  
搜索关键字:equals    ( 4544个结果
JAVA集合类——难得的总结
文是在学习中的总结,欢迎转载但请注明出处:http://blog.csdn.net/pistolove/article/details/41346969 以下资料是在学习中总结出来的,希望对你有所帮助。如果需要请转载,谢谢。 1. StringBuffer 线程安全,StringBuilder 线程不安全 效率稍高些 集(Set):集里的对象不按任何特定的方式排列,按索引值来操作数据,不能有重复的元素 列表(List):序列中的对象以线性方式存储,按索引值来操作数据,可以有重复的元素 映射(Map):映射...
分类:编程语言   时间:2014-11-24 22:35:03    阅读次数:282
为什么 IDEA 自带的 equals & hashCode generate 不好
多个member的 java bean,生成的 equals 代码基本没法读。 有个 plugin 用 spring commons 生成代码,spring commons 的 EqualsBuilder 的问题在于……confluence interface。 不知什么时候开始出现了一批迷信confluence interface的人,各种 method call chain...
分类:其他好文   时间:2014-11-24 10:05:28    阅读次数:255
【LeetCode】Path Sum II 解题报告
【题目】 Given a binary tree and a sum, find all root-to-leaf paths where each path's sum equals the given sum. For example: Given the below binary tree and sum = 22, 5 ...
分类:其他好文   时间:2014-11-23 17:34:18    阅读次数:163
【Leetcode】【Easy】Path Sum
Given a binary tree and a sum, determine if the tree has a root-to-leaf path such that adding up all the values along the path equals the given sum.Fo...
分类:其他好文   时间:2014-11-22 00:43:18    阅读次数:130
url 传中文
if (null == keyword || keyword.equals("关键字")) keyword = ""; if(keyword.length()> 0 ){ boolean isEnChar = true; for(int i = 0 ; i = 19968){ is...
分类:Web程序   时间:2014-11-21 18:19:19    阅读次数:130
C#中的虚方法和抽象方法(Thirteenth Day)
今天在云和学院学了很多,我这次只能先总结一下C#中的虚方法和抽象的运用。理论:?用virtual修饰的方法叫做虚方法?虚方法可以在子类中通过override关键字来重写?常见的虚方法:ToString() Equals实操:定义一个People的父类,包括Name,Gender,Age,和一个Pe....
分类:Windows程序   时间:2014-11-20 23:12:37    阅读次数:305
Path Sum II深度优先找路径
Given a binary tree and a sum, find all root-to-leaf paths where each path's sum equals the given sum.For example:Given the below binary tree andsum =...
分类:其他好文   时间:2014-11-20 14:54:26    阅读次数:230
温故而知新-String类
String不算是一种类型,而算是一个类,就是说String不仅可以表示string类型,还有一些自带的方法可以调用。温故而知新,现在给大家总结了String类应该注意的地方。 (1)“==”与“equals”的区别。 当两字符串用“==”比较时,比较的是引用,就是两字符串在内存中是否存储在同一个地方。 而“equals”则是比较两字符串的值。详见代码: {CSDN:CODE:M1m451...
分类:其他好文   时间:2014-11-20 13:47:26    阅读次数:177
Path Sum
Given a binary tree and a sum, determine if the tree has a root-to-leaf path such that adding up all the values along the path equals the given sum.Ja...
分类:其他好文   时间:2014-11-20 13:30:27    阅读次数:120
hashCode
如果两个对象相同,就是适用于equals(java.lang.Object)方法,那么这两个对象的hashCode一定要相同;两个对象的hashCode相同,并不一定表示两个对象就相同,也就是不一定适用于equals(java.lang.Object)方法,只能够说明这两个对象在散列存储结构中,如Hashtable,他们“存放在..
分类:其他好文   时间:2014-11-20 10:25:37    阅读次数:145
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!