how to find current day is weekday or weekends in Python? -


this question has answer here:

please suggest me on following. how find whether particular day weekday or weekend in python?

import datetime  weekno = datetime.datetime.today().weekday()  if weekno<5:     print "weekday" else:     print "weekend" 

Comments

Popular posts from this blog

How to group boxplot outliers in gnuplot -

cakephp - simple blog with croogo -