摘要:
1.文件编程概述 api open read/write lseek close 2.文件打开和创建#include<sys/types.h>#include<sys/stat.h>#include<fcntl.h> int open(const char *pathname,int flags)i 阅读全文
摘要:
#include<curses.h> #include<stdlib.h> #define UP 1 #define DOWN -1 #define LEFT 2 #define RIGHT -2 struct Snake { int hang; int lie; struct Snake *nex 阅读全文
摘要:
1.链表和数组区别及实现 #include<stdio.h> struct Test { int data; struct Test *next; }; int main() { int i; int arr[] = {1,2,3}; for(i=0;i<sizeof(arr)/sizeof(arr 阅读全文
摘要:
一.多维数组元素的地址 #include<stdio.h> int main() { int arr[3][4] = {{11,22,33,44},{12,13,15,16},{22,66,77,88}}; int i; int j; for(i=0;i<3;i++){ for(j=0;j<4;j+ 阅读全文