Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/gmelodie/cclock
CLI clock that divides time in 100, not 60
https://github.com/gmelodie/cclock
cli clock golang hacktoberfest
Last synced: 25 days ago
JSON representation
CLI clock that divides time in 100, not 60
- Host: GitHub
- URL: https://github.com/gmelodie/cclock
- Owner: gmelodie
- License: mit
- Created: 2019-11-22T00:44:22.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2021-03-18T15:02:35.000Z (over 3 years ago)
- Last Synced: 2024-06-19T11:29:30.719Z (5 months ago)
- Topics: cli, clock, golang, hacktoberfest
- Language: Go
- Homepage:
- Size: 4.51 MB
- Stars: 3
- Watchers: 2
- Forks: 2
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# cclock
Time measure divisible by 100, not 60Why the heck is a minute 60 seconds? Why on earth is an hour 60 minutes? Wouldn't it make much more sense if a minute were 100 seconds, and an hour 100 minutes?
Introducing centhclock (cclock): a time measure that turns time counting into something that *actually* makes sense.
A centhclock is composed by three basic time measures: centhconds (`cs`), centhutes (`ct`) and centhours (`ch`), where
```
1ch = 100ct
1ct = 100cs
1ch = 1h
```Which means that one hour should have `10^4` centhconds. Hence, all we have to do is convert the seconds in an hour to `10^4` centhconds:
```
1 hour = 60 * 60s = 3600s
```So 1 hour, which should have `10^4` centhconds, has `3600` seconds:
```
10^4cs = 3600s
1cs = 3600/10^4s = 0.360s
1s = 10^4/3600cs = 2.778cs
```Time measure | Centhconds | Centhutes | Centhours
---------------------|--------------------------|----------------|------------
1 Second | 2.777778 cs | 0.02777778 ct | 0.0002777778 ch
1 Minute | 166.66668 cs | 1.6666668 ct | 0.016666668 ch
1 Hour | 10000.0008 cs | 100.000008 ct | 1.00000008 ch
1 Day | 240000.01920 cs | 2400.0001920 ct | 24.000001920 chFor usage purposes, we can also think about each centhclock measure in terms of seconds, minutes and hours
Time measure | Seconds | Minutes | Hours
---------------------|--------------------------|----------------|------------
1 Centhcond | 0.35999997 s | 0.00599999952 min | 0.00009999999 h
1 Centhute | 35.999997 s | 0.599999952 min | 0.009999999 h
1 Centhour | 3599.9997 s | 59.9999952 min | 0.9999999 h