Thread kalender (13 answers)
Opened by popcorn5 at 2003-10-02 01:33

format_c
 2003-10-02 02:43
#59777 #59777
User since
2003-08-04
1706 Artikel
HausmeisterIn
[Homepage] [default_avatar]
*tipptipptipp*
Code: (dl )
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
use strict;
use warnings;
use Time::Local;
my %days;
@days{qw/0 1 2 3 4 5 6/} = qw/So Mo Di Mi Do Fr Sa/;

my $month = 2;
my $diff = timelocal(0,0,0,1,$month,2003-1900)-timelocal(0,0,0,1,$month-1,2003-1900);
my $tage = (localtime($diff))[7];
for (1..$tage) {
print sprintf("%02d: ",$_),
$days{(localtime(timelocal(0,0,0,$_,$month-1,2003-1900)))[6]},"\n";
}

01: Sa
02: So
03: Mo
04: Di
05: Mi
06: Do
07: Fr
08: Sa
09: So
10: Mo
11: Di
12: Mi
13: Do
14: Fr
15: Sa
16: So
17: Mo
18: Di
19: Mi
20: Do
21: Fr
22: Sa
23: So
24: Mo
25: Di
26: Mi
27: Do
28: Fr


Ist es dass was du willst?
Den Rest dürftest du eigentlich allein hinbekommen.

Gruß Alex\n\n

<!--EDIT|format_c|1065048311-->

View full thread kalender