# How to convert a Python datetime.datetime to excel serial date number # Python3 code to illustrate the conversion of# datetime.datetime to excel serial date number# Importing datetime moduleimport datetime# Calling the now() function to return# current date and timecurrent_datetime = datetime.datetime.now()# Calling the strftime() function to convert# the above current datetime into excel serial date numberprint(current_datetime.strftime('%x %X'))