Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

25 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Clockwork

CI passing

Basics

Do all your favorite clock things:

using Clockwork
@test 🕟+🕝== 🕔 # 3:30 + 1:30 == 5:00
@test 🕑^50 == 🕓
@test Clock("3:30") == 🕟
let cp = Dates.Hour(3) + Dates.Minute(30)
  @test Clock(cp) == 🕟
  @test Dates.CompoundPeriod(🕟) == cp
end

Clock algebra

julia> hooks_nightmare = rand(Clock,10,10)
10x10 Array{Clockwork.Clock,2}:
 🕠  🕢  🕙  🕧  🕦  🕧  🕙  🕘  🕚  🕝
 🕔  🕛  🕔  🕢  🕤  🕥  🕥  🕢  🕦  🕣
 🕓  🕒  🕐  🕝  🕐  🕥  🕘  🕙  🕦  🕕
 🕧  🕒  🕒  🕓  🕟  🕑  🕙  🕗  🕝  🕕
 🕘  🕚  🕟  🕙  🕒  🕞  🕓  🕔  🕥  🕧
 🕓  🕧  🕞  🕞  🕖  🕧  🕐  🕑  🕥  🕝
 🕔  🕣  🕔  🕙  🕠  🕔  🕖  🕞  🕢  🕕
 🕛  🕧  🕥  🕥  🕧  🕚  🕙  🕔  🕛  🕢
 🕕  🕗  🕝  🕧  🕧  🕥  🕕  🕓  🕤  🕘
 🕒  🕓  🕥  🕧  🕣  🕔  🕥  🕘  🕥  🕟
julia> hooks_nightmare * rand(Clock, 10, 2)
10x2 Array{Clockwork.Clock,2}:
 🕝  🕠
 🕗  🕑
 🕝  🕔
 🕐  🕘
 🕡  🕢
 🕧  🕚
 🕧  🕕
 🕛  🕝
 🕧  🕠
 🕛  🕤

About

Represent modular arithmetic via clock symbols

Resources

Stars

Watchers

Forks

Releases

Packages

Used by

Contributors

Languages