Pythonで日付/時刻の取得をする方法です。
# -*- coding: Shift_JIS -* import datetime print ("日付の取得") print (datetime.date.today()) print (datetime.date.today().year) print (datetime.date.today().month) print (datetime.date.today().day) print ("日付/時刻の取得") print (datetime.datetime.today()) print (datetime.datetime.today().hour) print (datetime.datetime.today().minute) print (datetime.datetime.today().second) print (datetime.datetime.today().microsecond)