python function. output a keys list from a dictionary if the key is todays date

i import datetime module. but i'm not sure how to call it as a dictionary key.

def bad_food():
    today = datetime.date.today()
    past_due = {
        datetime.date.today(2020,11,24): ['chicken' , 'soup', 'chips'],
        datetime.date.today(2020,11,27) : ['lays', 'chilli'],
                }
    for key in past_due:
        if key == today:
            print (today.values())
print(bad_food())```


from Recent Questions - Stack Overflow https://ift.tt/37cQwKl
https://ift.tt/eA8V8J

Comments

Popular posts from this blog

Today Walkin 14th-Sept

Spring Elasticsearch Operations

Hibernate Search - Elasticsearch with JSON manipulation