Answer to this question is 0.
but enthuware option tells as -1.
Attached screen shot.
About Question enthuware.ocpjp.v17.2.3791 :
Moderator: admin
-
- Posts: 2
- Joined: Mon May 30, 2022 1:48 pm
- Contact:
About Question enthuware.ocpjp.v17.2.3791 :
- Attachments
-
- Screenshot 2022-05-31 201247.png (128.46 KiB) Viewed 530 times
-
- Site Admin
- Posts: 10045
- Joined: Fri Sep 10, 2010 9:26 pm
- Contact:
Re: About Question enthuware.ocpjp.v17.2.3791 :
Actually, the answer needs to be as per the situation given in the question. The problem statement says that the daylight Savings Time ends on Nov 6th 2021 at 2 AM in US/Eastern time zone. Assuming this to be true, the answer will be -1.
Your program doesn't print -1 because DST didn't actually end on Nov 6th in 2021. In 2021, DST ended on Nov 7th. That is why you see 0. If you change the year to 2022 (or the date to 7), you will see -1.
Your program doesn't print -1 because DST didn't actually end on Nov 6th in 2021. In 2021, DST ended on Nov 7th. That is why you see 0. If you change the year to 2022 (or the date to 7), you will see -1.
If you like our products and services, please help us by posting your review here.
Who is online
Users browsing this forum: No registered users and 37 guests