Files
basic-computer-games/21_Calendar/perl
Tom Wyant f61148b2e4 Convert 21_Calendar to Perl.
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.
2022-01-11 21:19:47 -05:00
..
2022-01-11 21:19:47 -05:00
2022-01-11 21:19:47 -05:00

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.