题目:将自定义对象作为元素存到ArrayList集合中,并去除重复元素比如:存人对象,同姓名,同年龄,视为同一个人,为重复元素。/*
思路
1对人描述,将数据封装进人对象
2定义容器,将人存入
3取出
*/
importjava.util.*;
classPerson
{
privateStringname;
privateintage;
Pers..
分类:
其他好文 时间:
2014-12-03 10:38:55
阅读次数:
135
官网:http://www.cs.ubc.ca/~murphyk/Software/HMM/hmm.htmlDownloadClickhere. Unziping creates a directory called HMMall, which contains 4 subdirectories.I...
分类:
其他好文 时间:
2014-12-02 20:45:56
阅读次数:
172
描述
In this problem, you are given two integers L and R, and your task is to calculate the sum of all the number's square between L and R(inclusive).
输入The first line contains an integer ...
分类:
其他好文 时间:
2014-12-02 11:55:51
阅读次数:
181
字符串操作:字符串分割:String array[] = str.split("\t");列表操作:定义:List list=new ArrayList();添加元素:list.add("apple");判断是否包含某元素:list.contains("apple")hashmap操作:定义:Has...
分类:
编程语言 时间:
2014-12-01 18:57:28
阅读次数:
212
1510: Happy RobotTime Limit:1 SecMemory Limit:128 MBSubmit:19Solved:7DescriptionInputThere will be at most 1000 test cases. Each case contains a comma...
分类:
移动开发 时间:
2014-11-30 22:46:16
阅读次数:
267
http://blog.csdn.net/xuemoyao/article/details/193667551. Array的contains方法Array没有一个contains方法,在现实的应用场景是,有时候我们需要判断某一个值是否在该数组中,这个时候一个contains方法就显得很有必要,具体...
分类:
Web程序 时间:
2014-11-28 13:58:40
阅读次数:
206
Problem DescriptionGive you two numbers A and B, if A is equal to B, you should print "YES", or print "NO".Inputeach test case contains two numbers A ...
分类:
编程语言 时间:
2014-11-27 20:29:03
阅读次数:
224
Given a binary tree, determine if it is a valid binary search tree (BST).
Assume a BST is defined as follows:
The left subtree of a node contains only nodes with keys less than the node's key.Th...
分类:
其他好文 时间:
2014-11-27 16:30:19
阅读次数:
226
在使用jstl的函数标签库之前需要在页面中引入:1、fn:contains(string, substring) 如果参数string中包含参数substring,返回true。2、fn:containsIgnoreCase(string, substring) 如果参数string中包含参数sub...
分类:
Web程序 时间:
2014-11-27 15:55:58
阅读次数:
162
The set[1,2,3,…,n]contains a total ofn! unique permutations.By listing and labeling all of the permutations in order,We get the following sequence (ie...
分类:
其他好文 时间:
2014-11-27 14:16:46
阅读次数:
156