web analytics

Calculating the date of Easter

The easiest way is to use specialized package (like Date::Calc). If You need standalone function, the following method could be used.

#!/usr/bin/perl $year=$ARGV[ 0 ]; $isJulian=(defined($ARGV[ 1 ]) && $ARGV[ 1 ] eq ‘julian’); $isOrthodox=(defined($ARGV[ 1 ]) && $ARGV[ 1 ] eq ‘orthodox’); my ( $G , $C , $H, $I, $J , $L ); […]