1 public TreeNode sortedListToBST(ListNode head) { 2 if(head==null) return new TreeNode(0); 3 ArrayList arr=new ArrayList(); 4 ...
分类:
编程语言 时间:
2015-02-16 00:20:04
阅读次数:
230
一、什么是集群?
集群是一组计算机节点的集合,作为一个整体向用户提供一组网络资源。理想的集群对用户是透明的,用户由单一入口访问集群的资源,不会意识到集群的存在。集群可以随意添加节点也可以随意减少节点,这样不会影响用户的访问。
二、JBOSS
的Domain模式与Standalone模式
Standalone Mode是机器单进程方式,配置部署简...
分类:
其他好文 时间:
2015-02-15 21:53:17
阅读次数:
253
背景
Mesos粗粒度
Mesos细粒度背景顺着昨天spark standalone实现那篇文章继续扯淡,看看Mesos Scheduler的两种实现的异同。
对我来说,回过头再仔细看Spark在这一层的实现,思路又清晰了许多。Mesos粗粒度CoarseMesosSchedulerBackend,是mesos的粗粒度scheduler backend实现。简单说一下mesos的Scheduler...
分类:
其他好文 时间:
2015-02-15 16:39:01
阅读次数:
641
定义:Convert a interface of class into anthoer interface clients expect. Adapter let classes work together that could't otherwise because of incompat...
分类:
其他好文 时间:
2015-02-15 16:23:36
阅读次数:
146
这几个函数其实网上资料很多,但是为了方便自己的记忆,我还是决定还是写一下,都说好记性不如烂笔头,所以还是多写一下。cast()函数作用主要是:把一种类型转化成另外一种类型如把字符串类型转换成时间类型:SELECT CAST( '2011-10-2' AS datetime),再或者把数值型转换成字符...
分类:
数据库 时间:
2015-02-15 15:07:25
阅读次数:
179
我们在使用xmlhttprequest获取文本内容时,如果服务器返回的是gbk(或gb2312等非utf8编码)内容,那么得到的是一堆乱码,如何转换为浏览器内默认的utf8编码的文字?
其实如果您使用的是chrome 或 firefox浏览器,则非常简单,可以使用浏览器内置对象TextDecoder进行转换。
javascript示例代码:...
分类:
编程语言 时间:
2015-02-15 01:03:30
阅读次数:
292
Given an array where elements are sorted in ascending order, convert it to a height balanced BST.[Solution] 1 TreeNode *sortedArrayToBST(vector &num) ...
分类:
其他好文 时间:
2015-02-14 22:27:21
阅读次数:
220
地址: http://www.kandroid.org/ndk/docs/STANDALONE-TOOLCHAIN.htmlIt is now possible to use the toolchain provided with the Android NDK as a standalone co...
分类:
其他好文 时间:
2015-02-14 21:20:08
阅读次数:
303
ome commands to convert samba backend password-databases. If you use “passdb backend = smbpasswd” in your smb.conf you must convert your system-user a...
分类:
数据库 时间:
2015-02-13 23:36:32
阅读次数:
264
题目Given two words word1 and word2, find the minimum number of steps required to convert word1 to word2. (each operation is counted as 1 step.)You have the following 3 operations permitted on a word:a)...
分类:
其他好文 时间:
2015-02-13 19:59:56
阅读次数:
155