Traditional Culture Encyclopedia - The 24 Solar Terms - Date-based Java time birthday conversion algorithm.
Date-based Java time birthday conversion algorithm.
Please refer to: /view/ 158.htm#2 for the introduction of birthdays.
Specific algorithm:
1, set a lower limit year, for example, before 1960, 1960, do not check. There is also a perpetual calendar, which is the year of boxer.
2. Put heavenly stems and earthly branches in two columns.
3. Set the cycle with this year as the baseline and the query year as the upper limit year. Every year the loop counter is added, the array label of heavenly stems and earthly branches will be shifted by one to the right, and then if will judge whether the array is at the end, and if it is at the end, it will start from the beginning.
The algorithm of month and time is similar.
- Related articles
- Copy short sentences Dragon Boat Festival well-being wishes
- How to get out of the way
- Agricultural custom story of solar terms in the Spring Festival
- What are the daily necessities for middle-aged and elderly people?
- What solar term starts spring planting?
- What day is the solar term?
- What is the 80,000 km maintenance project of Toyota Lei Ling?
- What does it mean that Huanian can't get married?
- What does the Spring Festival mean?
- How to eat mango shrimp skin is the healthiest