datetime get date now code example
Example 1: print current date
from datetime import date
today = date.today()
print("Today's date:", today)
Example 2: get current date in python
from datetime import date
today = date.today()
print("Today's date:", today)