2.6内核
1>修改linux-source-2.6.31/kernel/sys.c文件,在文件末尾添加系统响应函数。函数实现如下:
asmlinkage int sys_mycall(int number)
{
printk("这是我添加的第一个系统调用");
return number;
}
2>在linux-source-2.6.31...
分类:
系统相关 时间:
2014-05-15 02:51:56
阅读次数:
382
水题。数字一共就9个,去掉1是用来显示标点的,剩下8个。
穷举一下map,然后有几个数字,就输出这几个数字的排列,是一个dfs嘛。
map num;
void allCombinations(string &digits, int start, int len, string &pres, vector &res){
if(len == digits.length()){
...
分类:
其他好文 时间:
2014-05-15 01:42:26
阅读次数:
264
Regular Expression Special Characters
"."---Any single character(a "wildcard")
"["---Begin character class
"]"---End character class
"{"---Begin count
"}"---End count
"("---Begin grouping
")"...
分类:
其他好文 时间:
2014-05-15 01:41:09
阅读次数:
548
Single Number II
Total Accepted: 14472 Total
Submissions: 44420My Submissions
Given an array of integers, every element appears three times except for one. Find that single one.
Note:
Y...
分类:
其他好文 时间:
2014-05-15 01:23:42
阅读次数:
273
Description
Businesses like to have memorable telephone numbers. One way to make a telephone number memorable is to have it spell a memorable word or phrase. For example, you can call the Universit...
分类:
其他好文 时间:
2014-05-15 00:20:39
阅读次数:
332
JS异常try { var n = prompt("Please enter a
positive number"); var f = factorial(...
分类:
编程语言 时间:
2014-05-14 23:46:00
阅读次数:
405
大部分的应用中的大部分的实体类型对象都可以使用key-value被序列化到JSON中。key就是field的name或这property,value是string,number,boolean,另外的对象,数组,或者其他的类型如用string表示的date类型,或者表示地理位置信息的对象。{
"n....
分类:
其他好文 时间:
2014-05-14 23:02:34
阅读次数:
390
【题目】
Implement regular expression matching with support for '.' and '*'.
'.' Matches any single character.
'*' Matches zero or more of the preceding element.
The matching should cover the entire input string (not partial).
The function prototype shoul...
分类:
其他好文 时间:
2014-05-14 21:36:52
阅读次数:
348
【题目】
Determine whether an integer is a palindrome. Do this without extra space.
【题意】
题意判断一个整数是否是回文数
注意一下几点:
1. 不能用额外的空间
2. 负数不是回文数...
分类:
其他好文 时间:
2014-05-14 20:31:10
阅读次数:
298
1、
??
Distinct Subsequences
Given a string S and a string T, count the number of distinct subsequences of T in S.
A subsequence of a string is a new string which is formed from the original str...
分类:
其他好文 时间:
2014-05-14 20:22:58
阅读次数:
275