#!/usrx/local/perldbn/perl
#######################################################################################
#  This program will retrieve the OSO status file from the SOC,  and 
# generate some statistical files for the SDM.
#
# Modifications:
#  01/27/97   Initial version
#
#######################################################################################

#######################################################################################
# Start Main Program
#######################################################################################
use Time::CTime;

$year="01";
$day="03";
$hour="01";
$min="17";
$sec="51";

$leapoffset=int(($year+28)/4);
      if(($year%4)==0)
         {
          if($day>=59)
             {
              $leapoffset=$leapoffset;
             }
          else
             {
              $leapoffset=$leapoffset-1;
             }
         }
      $pseconds = ($year+30) * 365 * 24 * 60 * 60 + ($day+$leapoffset) * 24 * 60 *60 + $hour * 60 * 60 + $min * 60 + $sec;


$nmctime=strftime("%Y-%m-%d-%H-%M-%S",gmtime($pseconds));

print "$nmctime\n";
