■ strftime 함수 : 날짜/시간 포맷 문자열 구하기

----------------------------------------------------------------------------------------------------

import time

 

format = '%Y-%m-%d'

result = time.strftime(format, time.localtime(time.time()))

print(result)

 

[결과]


'2017-12-15'

----------------------------------------------------------------------------------------------------

Posted by 사용자 icodebroker
TAG