电脑桌面
添加小米粒文库到电脑桌面
安装后可以在桌面快捷访问

C语言函数大全VIP专享

C语言函数大全_第1页
1/344
C语言函数大全_第2页
2/344
C语言函数大全_第3页
3/344
下载后可任意编辑C 语言函数大全(语法着色版)A 函数名: abort功 能: 异常终止一个进程用 法: void abort(void);程序例:#include #include int main(void){ printf("Calling abort()\n"); abort(); return 0; /* This is never reached */}函数名: abs功 能: 求整数的绝对值用 法: int abs(int i);程序例:#include #include int main(void){ int number = -1234; printf("number: %d absolute value: %d\n", number, abs(number)); return 0;}下载后可任意编辑函数名: absread, abswirte功 能: 绝对磁盘扇区读、写数据用 法: int absread(int drive, int nsects, int sectno, void *buffer); int abswrite(int drive, int nsects, in tsectno, void *buffer);程序例:/* absread example */#include #include #include #include int main(void){ int i, strt, ch_out, sector; char buf[512]; printf("Insert a diskette into drive A and press any key\n"); getch(); sector = 0; if (absread(0, 1, sector, &buf) != 0) { perror("Disk problem"); exit(1); } printf("Read OK\n"); strt = 3; for (i=0; i<80; i++) { ch_out = buf[strt+i]; putchar(ch_out); } printf("\n"); return(0);}下载后可任意编辑函数名: access功 能: 确定文件的访问权限用 法: int access(const char *filename, int amode);程序例:#include #include int file_exists(char *filename);int main(void){ printf("Does NOTEXIST.FIL exist: %s\n", file_exists("NOTEXISTS.FIL") ? "YES" : "NO"); return 0;}int file_exists(char *filename){ return (access(filename, 0) == 0);}函数名: acos功 能: 反余弦函数用 法: double acos(double x);程序例:#include #include int main(void){ double result; double x = 0.5; result = acos(x); printf("The arc cosine of %lf is %lf\n", x, result); return 0;}下载后可任意编辑函数名: allocmem功 能: 分配 DOS 存储段用 法: int allocmem(unsigned size, unsigned *seg);程序例:#include

1、当您付费下载文档后,您只拥有了使用权限,并不意味着购买了版权,文档只能用于自身使用,不得用于其他商业用途(如 [转卖]进行直接盈利或[编辑后售卖]进行间接盈利)。
2、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。
3、如文档内容存在违规,或者侵犯商业秘密、侵犯著作权等,请点击“违规举报”。

碎片内容

C语言函数大全

确认删除?
微信客服
  • 扫码咨询
会员Q群
  • 会员专属群点击这里加入QQ群