+ 1

Can anyone tell me the error in this

It is taking wrong time, why? https://code.sololearn.com/cvxwVeoSPqXQ/?ref=app

17th Sep 2020, 3:09 PM
Arpit Tiwari
2 Réponses
+ 3
probably its printing the time where server is located not according to the location where user is , You can use this to get time according to country import pytz IST=pytz.timezone('Asia/Kolkata') a=datetime.datetime.now(IST)
17th Sep 2020, 3:25 PM
Abhay
Abhay - avatar
+ 1
Thanks, it helped😄
17th Sep 2020, 3:30 PM
Arpit Tiwari