现在,我正试图用调度器在python中做一个提醒。我使用了schedule.every().tuesday.at("21:35").do(reminder)方法,但我希望用户输入日期和时间,而不是在编码中设置。是否有办法这样做?编码:
remind = input("What should i remind about?")
DAY = input("Which Day?")
Time = input("Time?")
schedule.every().(DAY).at(Time).do(print(remind))
while True:
schedule.run_pending()发布于 2022-11-08 13:52:55
user_input = input("Enter a date")
# do whatever you want with the input
print(user_input)您应该考虑从输入中提取日期和时间。这取决于你想要什么。
https://stackoverflow.com/questions/74361759
复制相似问题