Help for this page

Select Code to Download


  1. or download this
    $ perl -wE'my($m,$y)=(localtime)[4,5];--$m<0 and($m,$y)=($m+12,$y--);s
    +ay $m+1,"-",$y+1900;'
    9-2018
    
  2. or download this
    sub previous_month {
        my ($month, $year) = @_; # month = 1..12
    ...
        } # previous_month
    
    say for previous_month (10, 2018);