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
- 자바스크립트
- 보험
- python
- 문자열
- Java
- 프론트엔드
- jQuery
- 중도인출
- 뇌출혈
- 납입
- 추가납입
- 심장질환
- 리스트
- 급성심근경색증
- 가입
- 보험료
- 수수료
- 인출수수료
- 웹개발
- 교보
- 코딩
- 특약
- javascript
- 변환
- 교보생명
- 파이썬
- PythonProgramming
- Vue.js
- 사망
- 프로그래밍
Archives
- Today
- Total
목록날짜와시간 (1)
SeouliteLab
[Python/파이썬] 파일 생성 및 수정 날짜 가져오기
import os import datetime def get_file_dates(file_path): # 파일 생성일자 가져오기 creation_time = os.path.getctime(file_path) creation_date = datetime.datetime.fromtimestamp(creation_time) # 파일 수정일자 가져오기 modification_time = os.path.getmtime(file_path) modification_date = datetime.datetime.fromtimestamp(modification_time) return creation_date, modification_date # 테스트용 파일 경로 file_path = 'example.txt'..
카테고리 없음
2024. 4. 24. 09:06