1970 in the programming language

Source: Internet
Author: User

Many programming languages in the time to start from January 1, 1970 0 o'clock, the previous period of time Apple mobile phone brick problem, is caused by this time point, that 1970 where the magic? Today we will discuss this issue.

One of the most lazy ways to interpret this is:

Many programming languages originate from UNIX systems, and UNIX systems think January 1, 1970 0 O'Clock is the time era, so we often say that the Unix timestamp is January 1, 1970 0 o'clock as the starting time.

There is a lazy explanation that may also solve our 1970 confusion, however, some people will ask, why the UNIX system starting from January 1, 1970 era?

Second, let's take a closer look at the reasons for this:

First, let's take a look at the computer of the initial 32-bit system:
The computer operating system is 32 bits, and the time is represented by 32 bits.

Maximum value 32 bits can store: 2147483647

In addition 1 years the total number of seconds 365 days is 31536000,2147483647/31536000 = 68.1, that is, 32 bits can represent the maximum time is 68 years. 68 is the longest lifetime of 32-bit operating systems.

From 1970 onwards, plus 68.1, the actual final to January 19, 2038 03:14 07 seconds, will reach the maximum time, over this point in time, all 32-bit operating system time will become 10000000 00000000 00000000 00000000, it is December 13, 1901 20:45 52 seconds, so there will be time to return to the phenomenon, a lot of software will run the exception.

The earliest UNIX operating system took into account the age of the Computer Generation (1946) and the time-to-use of the application to take January 1, 1970 as the time of the Unix era (start time).

That time return phenomenon!!!

As for the phenomenon of time regression, I believe that with the 64 of the operating system is gradually resolved, because 64-bit operating system can be represented to 292,277,026,596 December 4 15:30 08 seconds, believe that our generation of n generations, even if the day of the destruction of the earth will not worry enough, Because this time is hundreds of years later.

As for some of the 2001 of the language is mostly into the new century!

1970 in the programming language

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.