Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

compare two datetime in python

    jan_1_2020 = datetime.datetime(2020, 1, 1)
    dec_12_2020 = datetime.datetime(2020, 12, 12)

    if (jan_1_2020 < dec_12_2020):
        # ...


# More examples are at https://docs.python.org/3/library/datetime.html
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #compare #datetime #python
ADD COMMENT
Topic
Name
9+1 =