码迷,mamicode.com
首页 >  
搜索关键字:List 集合    ( 93165个结果
Java多线程编程初识
每个正在系统上运行的程序都是一个进程。每个进程包含一到多个线程。进程也可能是整个程序或者是部分程序的动态执行。线程是一组指令的集合,或者是程序的特殊段,它可以在程序里独立执行。也可以把它理解为代码运行的上下文。所以线程基本上是轻量级的进程,它负责在单个程序里执行多任务。通常由操作系统负责多个线程.....
分类:编程语言   时间:2014-05-07 17:32:42    阅读次数:378
多线程下的共享资源列表
1、采用queue,而不是采用list遍历2、添加两个锁,读锁和写锁
分类:编程语言   时间:2014-05-07 14:07:12    阅读次数:223
Remove Duplicates from Sorted List II
Given a sorted linked list, delete all nodes that have duplicate numbers, leaving onlydistinctnumbers from the original list.For example,Given1->2->3-...
分类:其他好文   时间:2014-05-07 13:42:51    阅读次数:278
69 Spring Interview Questions and Answers – The ULTIMATE List--reference
This is a summary of some of the most important questions concerning the Spring Framework, that you may be asked to answer in an interview or in an in...
分类:编程语言   时间:2014-05-07 01:48:25    阅读次数:601
Java创建(读取)比较复杂的JSON对象
使用Java创建比较复杂的JSON对象,代码如下: 1 import java.util.ArrayList; 2 import java.util.HashMap; 3 import java.util.List; 4 5 import net.sf.json.JSONArray; 6 impo....
分类:编程语言   时间:2014-05-07 01:41:20    阅读次数:439
C#&Java重学笔记(集合比较和转换)
C#部分:1.C#中集合有三种,数组类,ArrayList,和字典键值对类,一般也可以自定义集合,但是自定义集合的类型也只有这三类。2.自定义集合实现三类集合的方法:前两者需要继承CollectionBase类,Array需要使用List属性,ArrayList需要使用InnerList属性,后一种...
分类:编程语言   时间:2014-05-07 01:27:42    阅读次数:396
java List排序方法 Comparator和Comparable
今天写的一个程序中需要对一个List进行排序,突然发现自己对这个问题一无所知,于是查阅资料并进行测试,在此做个记录。Collections工具类中有两个方法可以对List进行排序,分别为:public static > void sort(List list)public static void ....
分类:编程语言   时间:2014-05-07 00:57:29    阅读次数:345
hdu 1856 More is better
http://acm.hdu.edu.cn/showproblem.php?pid=1856这道题就是求一个集合里面最大的个数。 基本的并查集加一个步骤,将合并后的元素的个数保存在新的树根中。 1 #include 2 #include 3 #include 4 #define maxn 10...
分类:其他好文   时间:2014-05-07 00:47:33    阅读次数:370
复习java基础第四天(集合)
List 代表一个元素有序、且可重复的集合,集合中的每个元素都有其对应的顺序索引List 允许使用重复元素,可以通过索引来访问指定位置的集合元素。 List 默认按元素的添加顺序设置元素的索引。List 集合里添加了一些根据索引来操作集合元素的方法:另外:List 额外提供了一个 listItera...
分类:编程语言   时间:2014-05-07 00:16:29    阅读次数:349
Merge Two Sorted Lists
Merge Two Sorted ListsMerge two sorted linked lists and return it as a new list. The new list should be made by splicing together the nodes of the fir...
分类:其他好文   时间:2014-05-06 23:54:10    阅读次数:469
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!