Python: Afficher l’heure en format Integer

Author:

 date
{filelink=16875}

 
import time
 
now = time.time()
tm = time.localtime(now)
 
print "date->", now
 
print now
print time.mktime(tm)
 
"""
date-> 1345893254.0
1345893254.0
1345893254.0
 
"""

Livres Sur ce Sujet

Apprendre à programmer avec Python 3 Apprenez à programmer en Python Python : Petit guide à l’usage du développeur agile Apprendre à programmer avec Python 3 : Avec plus de 50 pages de corigés d’exercices !

Leave a Reply

Your email address will not be published. Required fields are marked *


+ seven = 8