Perl und Time Funktion

Perl Logo
Perl Logo

Sehr oft muss man die Zeit-Funktionen verwenden, um die genaue Zeit und/oder Datum zu ermitteln. In diesem Beispiel wird das Datum ausgegeben:

$t=time()+3600;
# 0 1 2 3 4 5 6 7 8
($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime($t);
$year += 1900; $mon++;
if ($mon<10){$mon=”0$mon”;}
if ($mday<10){$mday=”0$mday”;}
print “$mday $mon $year”;

$t_string=scalar localtime($t);
print “$t_string”;

6 Trackbacks / Pingbacks

  1. webpage
  2. empresa informática
  3. Golden Teacher Mushrooms
  4. สล็อตเว็บตรง
  5. here
  6. auto swiper

Leave a Reply to Anonymous Cancel reply

Your email address will not be published.