Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | ||
6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 | 14 | 15 | 16 | 17 | 18 | 19 |
20 | 21 | 22 | 23 | 24 | 25 | 26 |
27 | 28 | 29 | 30 | 31 |
Tags
- YOLO
- windows forms
- Docker
- Selenium
- SSH
- Numpy
- pandas
- 프로그래머스
- mysql
- 채보
- VS Code
- LIST
- 핑거스타일
- paramiko
- label
- C#
- Visual Studio
- error
- 명령어
- Python
- JSON
- ubuntu
- OpenCV
- C
- pytorch
- 오류
- 기타
- 기타 연주
- C++
- Linux
Archives
- Today
- Total
목록File (1)
기계는 거짓말하지 않는다
C 파일 존재 여부, File Exist Check
C언어 파일 존재여부 확인 Linux #include if( access( f_path, F_OK ) != -1 ) { // 파일 존재 } else { // 파일 없음 } stat 구조체 이용 #include bool exist_file (char *file_name) { struct stat buffer; return (stat (file_name, &buffer) == 0); } FILE 구조체 이용 #include FILE *file; if (file = fopen("temp.txt", "r")) { fclose(file); printf("파일 존재\n"); } else { printf("파일 없음\n"); }
C
2022. 5. 13. 17:38