mirror of
https://github.com/coding-horror/basic-computer-games.git
synced 2025-12-22 23:26:40 -08:00
This is pretty much a complete rewrite. It displays the current year, but that can be changed by specifying the desired year on the command line. It MAY even be sensitive enough to locale to produce output in languages other than English.
Original source downloaded from Vintage Basic
Conversion to Perl
Actually, this is not so much a port as a complete rewrite, making use of Perl's Posix time functionality. The calendar is for the current year (not 1979), but you can get another year by specifying it on the command line, e.g.
perl 21_Calendar/perl/calendar.pl 2001
It may even produce output in languages other than English. But the leftmost column will still be Sunday, even in locales where it is typically Monday.