Skip to main content
We’ve updated our Terms of Service. A new AI Addendum clarifies how Stack Overflow utilizes AI interactions.
Code Golf

Timeline for Calculate Swatch Internet Time

Current License: CC BY-SA 3.0

10 events
when toggle format what by license comment
Jul 24, 2016 at 22:03 comment added veganaiZe @Andrea Thank you. Edited.
Jul 24, 2016 at 7:11 history edited veganaiZe CC BY-SA 3.0
Trimmed 2 more bytes.
Jul 16, 2016 at 0:22 comment added mystery Hmm, doesn't %03.f round up? That would give inaccurate results.
Jul 13, 2016 at 20:51 comment added mystery Also, you could save space by omitting the two includes, and replacing the NULL with 0.
Jul 13, 2016 at 20:50 comment added mystery This contains a bug. It doesn't do a modulo after correcting the time-zone, it does it before, which means between 23:00–0:00 UTC (i.e. 0:00–1:00 UTC+1), it incorrectly produces a four-digit number. You could fix this by changing time(NULL)%86400+3600 to (time(NULL)+3600)%86400.
Jul 12, 2016 at 1:52 history edited veganaiZe CC BY-SA 3.0
Explanation
Jul 12, 2016 at 1:28 history edited veganaiZe CC BY-SA 3.0
removed space
Jul 12, 2016 at 1:21 history edited veganaiZe CC BY-SA 3.0
minified and zero padding added.
Jul 11, 2016 at 12:09 comment added cat For future reference: you should post the golfed version of the code, and, at your option, an ungolfed version or test program below.
Jul 11, 2016 at 4:13 history answered veganaiZe CC BY-SA 3.0

AltStyle によって変換されたページ (->オリジナル) /