반응형
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
- Apache
- django
- Kotlin
- gas
- google apps script
- math
- matplotlib
- Redshift
- hive
- c#
- Excel
- Java
- list
- Tkinter
- Google Excel
- PANDAS
- Python
- GIT
- array
- string
- PySpark
- PostgreSQL
- Github
- Mac
- numpy
- 파이썬
- SQL
- Google Spreadsheet
- dataframe
Archives
- Today
- Total
목록os.path.exists (1)
달나라 노트
Python os : os.path.exists (directory 또는 file 존재 여부 확인)
Syntax os.path.exists(file_path) os.path.exists는 위처럼 사용 가능합니다. parameter로서 file_path를 받으며 file_path가 실제로 존재하면 True를 존재하지 않으면 False를 반환합니다. |-- test.py |-- test |-- sub_test |-- test.csv # test.py import os print(os.path.exists('test/')) # 1 print(os.path.exists('test/empty_test/')) # 2 print(os.path.exists('test/sub_test/test.csv')) # 3 -- Result True False True 위 예시를 봅시다. python code는 test.py에 ..
Python/Python os
2021. 6. 30. 13:43