http://zhangshixi.iteye.com/blog/672697
2011-6-14
http://zhangshixi.iteye.com/category/101360
2011-6-14
http://blog.csdn.net/java2000_net/archive/2009/10/19/4696661.aspx
http://blog.csdn.net/java2000_net/archive/2009/03/19/4003498.aspx
http://blog.csdn.net/java2000_net/archive/2009/03/08/3968189.aspx
http://blog.csdn.net/java2000_net/archive/2008/12/26/3610370.aspx
http://blog.csdn.net/java2000_net/archive/2008/10/18/3097304.aspx
http://blog.csdn.net/java2000_net/archive/2008/10/17/3092206.aspx
http://blog.csdn.net/java2000_net/archive/2008/10/09/3039346.aspx
http://blog.csdn.net/java2000_net/archive/2008/10/06/3023517.aspx
http://blog.csdn.net/java2000_net/archive/2008/10/06/3019580.aspx
http://blog.csdn.net/java2000_net/archive/2008/09/25/2975636.aspx
2011-6-19
treemap可以存储 key值是实体,value值是LinkedList 吗? 2011-6-23
public static String getReverseString (String s) {
StringBuffer sb = new StringBuffer();
for (int i = s.length(); i > 0; i--) {
sb.append(s.substring(i - 1, i));
}
return sb.toString();
}
//四个数为24.
package org.string.com;
import java.util.*;
// 把里面的l换成u;
public class TestString {
public static void main(String[] args){
int[]arr={0,20,4,0};
List<Integer> list=new ArrayList<Integer>();
list.add(arr[0]);
for(int i=1;i<arr.length;i++){
list=getaList(list,arr[i]);
}
boolean flag=false;
for(int i=0;i<list.size();i++){
if(list.get(i)==24){
flag=true;
}
}
System.out.println(flag);
}
static List getaList(List<Integer> arr,int c){
List<Integer> list=new ArrayList<Integer>();
for(int i=0;i<arr.size();i++){
list.add(arr.get(i).intValue()+c);
list.add(arr.get(i).intValue()-c);
list.add(arr.get(i).intValue()*c);
if(c!=0)list.add(arr.get(i).intValue()/c);
list.add(c-arr.get(i).intValue());
list.add(arr.get(i).intValue()*c);
if(arr.get(i).intValue()!=0)list.add(c/arr.get(i).intValue());
}
return list;
}
}