Skip to content

Instantly share code, notes, and snippets.

@wjzhangq
Created April 29, 2019 08:30
Show Gist options
  • Save wjzhangq/e11eecb784f749d21a6bf7023305c1af to your computer and use it in GitHub Desktop.
Save wjzhangq/e11eecb784f749d21a6bf7023305c1af to your computer and use it in GitHub Desktop.
时间函数
def my_date(unixtime, format='%m/%d/%Y %H:%M'):
d = datetime.datetime.fromtimestamp(unixtime)
return d.strftime(format)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment