Year(s) Month(s) Day(s) between 2 dates
|
10-21-2015, 01:10 PM
(This post was last modified: 10-21-2015 01:33 PM by Dieter.)
Post: #6
|
|||
|
|||
RE: Year(s) Month(s) Day(s) between 2 dates
(10-19-2015 09:33 AM)ggauny@live.fr Wrote: I wonder if it's a way to load in one list the "31 STO 01 STO 03 etc.", I've check anywhere but I don't find. You do not need a list, you can compute the number of days in a month directly. It's just 12 steps on the 34s: Code: 01 RCL X If you perfer a closed formula instead of a test: n = 28 + (m + m div 8) mod 2 + 2 · abs(sign(m–2)). And if February is neglected (:= 30 days) it even boils down to 30 + (m + m div 8) mod 2. By the way... (10-19-2015 09:33 AM)ggauny@live.fr Wrote: This routine is precise because we work with really numbers of days into month ...in many cases there is no "precise" result. The number of days depends on how you count them. This was already discussed in march when we have been talking about this topic in another thread (cf. post #9 and #12). Dieter |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 13 Guest(s)