select函数允许程序同时在多个底层文件描述符下等待输入完成,这意味着终端仿真程序可一直阻塞到有事可做为止。select系统调用原型:1 #include 2 #include 3 4 int select(int nfds, fd_set *readfds, fd_set *write...
分类:
其他好文 时间:
2014-11-22 17:15:05
阅读次数:
181
一、JAVA基础知识点问答(1、2、3章)1、JDK1.6.0_06软件的安装。(请安装在C:\Java目录下)2、JAVA的开发环境如何配置?(即:JAVA_HOME、Path、CLASSPATH的配置)3、开发一个JAVA应用程序的步骤是?(如下程序)publicclassFirstSample...
分类:
编程语言 时间:
2014-11-22 15:59:15
阅读次数:
298
Given a m x n grid filled with non-negative numbers, find a path from top left to bottom right which minimizes the sum of all numbers along its path.
Note: You can only move either down or right at...
分类:
其他好文 时间:
2014-11-22 14:45:18
阅读次数:
141
TCP段是封装在IP数据报中传输的,而IP数据报的传输是不可靠的。因此,不能将TCP段发送出去后就不再管它们了,相反必须跟踪它们,直到出现三种情况为止:一是在规定时间内接收方确认已收到该段;二是发送超时,即规定时间内未收到接收方的确认;三是确定数据包已丢失,在后两种情况下需从未接收的位置开始重新发送该数据报。
从图中可以看出TCP传输控制块中sk_write_queue字段存储的是发送队...
分类:
其他好文 时间:
2014-11-22 14:41:21
阅读次数:
257
#includeusing namespace std;int main(int count,char *[]){ int a[10]={9,8,7,6,5,4,3,2,1,0}; int temp=0; int n=10; for(int i=0;ia[j+1]) ...
分类:
编程语言 时间:
2014-11-22 12:02:28
阅读次数:
200
在看区别之前,首先来看下以下代码:public class TestEqual { /** * @param args * I am not responsible of this code. * They made me write it, against my...
分类:
其他好文 时间:
2014-11-22 12:00:39
阅读次数:
141
题意:一棵 n 个结点的树,树边有权值w(0
题目链接:http://poj.org/problem?id=3764
——>>取0为根,预处理出所有结点到根的异或xOr[i]。那么结点 a 与结点 b 之间的路径异或就是xOr[a] ^ xOr[b]。。
权值 w 最多31位,于是,将每个xOr的二进制表示从高位到低位插入到 01 Trie中(0为0,非0为1)。。
查询时从高位开始贪心...
分类:
其他好文 时间:
2014-11-22 10:40:33
阅读次数:
230
1.新WEB工程,并把编码设为utf-8:XbyOA->Properties->others->utf-8;2.添加框架环境:Junit + Struts2 + Hibernate + Spring; 【加jar包 + 拷配置文件 + 修改配置文件】 【1】XbyOA->bulid path->Ad...
分类:
系统相关 时间:
2014-11-22 09:11:33
阅读次数:
279
以Blog举例载入项目入口文件 D:\wamp\www\Examples\Blog\index.php 定义常量 APP_NAME,Blog APP_PATH,D:\wamp\www\Examples\Blog\ (APP_PATH为项目核心框架结构文件(lib)所在目录)载入ThinkPHP...
分类:
Web程序 时间:
2014-11-22 07:02:29
阅读次数:
138
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