p5.2.c
来自「linux程序设计例程」· C语言 代码 · 共 22 行
C
22 行
#include <stdio.h>#include <sys/types.h>#include <sys/stat.h>#include <fcntl.h>int main(void){ int fd1; if((fd1=open("test1",O_CREAT | O_RDWR,0777))==-1){ perror("Cannot create the test2 file"); return 1; } if(close(fd1)==-1){ perror("Close call failure"); return 1; }; return 0;}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?