about summary refs log tree commit diff
path: root/lang/thinkraku/human-seconds.raku
blob: 610213e7cc69908775934d6e54c64c8ff1e7b860 (plain) (blame)
1
2
3
4
5
6
7
8
#!/usr/bin/env raku
# Exercise 4.1
sub MAIN(Int $seconds=240_000) {
    put 'Days: ', $seconds div 86400;
    put 'Hours: ', $seconds div 3600 % 24;
    put 'Minutes: ', $seconds div 60 % 60;
    put 'Seconds: ', $seconds % 60
}