&gettime;
print "$date\n";


sub gettime {
  $use_time=0;

   ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime(time);

   $month = ($mon + 1);

   if ($sec < 10) {
      $sec = "0$sec";
   }
   if ($min < 10) {
      $min = "0$min";
   }
   if ($hour < 10) {
      $hour = "0$hour";
   }
   if ($month < 10) {
      $month = "0$month";
   }
   if ($mday < 10) {
      $mday = "0$mday";
   }

   @months = ("JAN","FEB","MAR","APR","MAY","JUN","JUL","AUG","SEP","OCT","NOV","DEC");

   if ($use_time == 1) {
      $date = "$hour\:$min\:$sec $month/$mday/$year";
   }
   else {
      if ($year > 70)
      {
	 $year = "19$year";
      }
      else 
      {
	$year = "20$year";
      }
      $date = "$month$mday$year";
   }
   chop($date) if ($date =~ /\n$/);

   #$long_date = "$mday-$months[$mon]-19$year  $hour\:$min\:$sec";
}     
