DEV Community

Cover image for Understanding Time zones
b-meet
b-meet

Posted on • Updated on

Understanding Time zones

Let's talk about time-zone, before that you need to know:

  • latitude - imaginary horizontal lines on earth's surface
  • longitude - imaginary vertical lines on earth's surface

latitude and longitude

Now latitude/longitude being clear lets move back to the topic.


What actually is time zone?

Timezone is a region/area which experiences a same time. that means if you travel longitudinally, then you won't experience any change in time zone

How are time zones made?

Earth rotates at equator with speed of 1000miles per hour.
The earths rotation is directly related to our time. So if we calculate then earth rotates about 15deg every hour.
That means total number of hours in a day are 24hr

360/15 = 24hours

if you look from top-view (north-pole) then you would find a line passing through north-pole. One of its side is called prime meridian and other one is called international dateline.

prime meridian and international dateline

If we go towards western hemisphere then we need to subtract 1hr every 15degs and vice-versa.

prime meridian and international dateline

so if its 12am at prime meridian then it will be 12pm at international dateline.

There are name given to every time zone and we call it as IST,PST,PDT etc... GMT & UTC have no time difference. Prior to 1972, this time was called Greenwich Mean Time (GMT) but is now referred to as Coordinated Universal Time or Universal Time Coordinated (UTC).

Also there are political changes made in time zone value i.e, some countries prefer to stay in other time zone to keep things little less complicated and more maintainable.

Conclusion

So now I hope you have good knowledge about time zones. Now you might get a little help in using Date constructors etc... 😅

Stay happy, Keep your surroundings clean,
Signing off Meet Bhalodiya,

Peace ✌

Top comments (0)