Here's a simple one:
[box=ffeedd]use stat(x), where x is:
80..85 UTC time: year, month, day, hour, minute, second 90..95 Local time[/box]
Go crazy, guys!
Sweet. Once there are some math functions for date/time, this will be awesome.
I might try to port some of my PHP time stuff over but might not be the same thing...hmmm...
You know, stuff like: days_diff(t,n), hours_diff(t,n), add_to_date()...
At 163 chars, I was gonna say here's another failed #tweetcart attempt, but since Twitter just went crazy with tweet length... :D
This clock is based on the code from an earlier cart, which was itself based on the code at https://maximecb.github.io/Turing-Drawings/. It converts the current time and date to a base-48 number, then creates a Turing machine transition entry for each "digit" in the number in order to draw the patterns you see (48 = 3 symbols * 4 states * 4 directions). There are only enough seconds since 1 AD to fill up the first 7 entries of 12 (the number of seconds is approximately 7 digits in base 48), so the last 5 entries are randomized instead. Every second it changes the rules based on the new current time, and every minute it clears the screen.
[Please log in to post a comment]