in reply to Re: Leap second coming up. Check your date handling code
in thread Leap second coming up. Check your date handling code

60 can be divided by 1, 2, 3, 4, 5, 6 and 10. Because of this, you can avoid many fractions.

perl -E 'for $i (1..10){say "60/$i=".(60/$i)}'

Same goes for 360 perl -E 'for $i (1..360){say "360/$i=".($_=360/$i)unless(($_=360/$i)-int($_))}'

Now, base 10 time is not a new concept: metric time. It does take some time to get used to, though. (but at least you will not be ruled by Babylonian time anymore)

Speaking of Integers: I feel bad for you, son. I got .99999999 problems, and a float ain't one......

Replies are listed 'Best First'.
Re^3: Leap second coming up. Check your date handling code
by perldigious (Priest) on Dec 28, 2016 at 20:46 UTC

    Huh, I learned something today. Kudos, and despite the handy even division by the first 6 natural numbers, metric time still sounds pretty appealing to me if we had jumped on it a lot sooner in human history (pre-industrial revolution would have been nice). Our current physical measurement definitions for so many units being based on seconds having to be changed would be a massive shock to the system Système Internationale. I don't mind floats, but I don't want to get in to a pointed argument... :-)

    Mmm, delicious nostalgia.

    Just another Perl hooker - Yes, I'll do really dirty code, but I charge extra.
      Yes, But isn't it nice that 24 hours are actually made up of three 8 hour blocks. (and 8 is... well, a digital number, like 8 bits). And so you have 1/3 sleep, 1/3 work and 1/3 leisure time? ( where sleeping is false, working is true, and leisure is undef )

        Wait, don't you mean 0.333333333333333333...? :-)

        Apparently leisure is a word of French origin for a reason. Of course that presumably makes their fractions 1/3 sleep, 7/24 work, and 3/8 leisure. Sacre bleu!

        Total tangent, an old friend of mine knows a bit of French, and has recently been trying to learn Russian. He described French to me as, "A language that leaves native English speakers desperately searching for consonant sounds that aren't there," and Russian as, "A language that leaves native English speakers desperately searching for vowel sounds that aren't there." Don't know if that's an original line of his or someone else he is quoting, but it made me chuckle none the less.

        Just another Perl hooker - Yes, I'll do really dirty code, but I charge extra.