- or download this
+-----------+ +-----------+
| O-----+----->| 12345 |
+-----------+ +-----------+
- or download this
+----------\ +----------\
| a > | b >
...
+-----------+ +-----------+
| O-----+----->| 12345 |
+-----------+ +-----------+
- or download this
+----------\
| b > +----------\
...
+-----------+ +-----------+
| O-----+----->| Qux |
+-----------+ +-----------+
- or download this
+----------\
| a > +-->+###########+
...
| Baz |
+-----------+
- or download this
+----------\
| a > +-->+###########+
...
| Baz |
+-----------+
- or download this
$aref = [123, 456, 789];
- or download this
$href = {NAME => 'Bernd', EMAIL => 'bdulfer@sybase.com'};
- or download this
$fref = sub { print "AnonSub\n" };
- or download this
use Data::Dumper;
...
my @b = (1, 2, 3, 4);
make_hash_from_arrays(\@a, \@b);
- or download this
$address{Bernd} = 'Bernd Dulfer|Kapellenstr. 1|bdulfer@sybase.com'
+;
$email = (split(/\|/, $address{bernd}))[2];
- or download this
$name{Bernd} = 'Bernd Dulfer';
$str{Bernd} = 'Kapellenstr. 1';
$email{Bernd} = 'bdulfer@sybase.com';
print_address($name{Bernd}, $str{Bernd});
- or download this
+----------\
| address >
...
$email = $address{Bernd}->{EMail};
print_address($address{Bernd});
- or download this
+----------\
| address >
...
'The Color of Magic'
]
};
- or download this
$s = 'qwertz';
$sref = \$s;
print ${$sref}, "\n";
print $$sref, "\n";
- or download this
qwertz
qwertz
- or download this
$, = ':';
@a = (123, 456, 789);
$aref = \@a;
print @{$aref}, "\n";
print @$aref, "\n";
- or download this
123:456:789
123:456:789
- or download this
${$aref}[1]
or
$$aref[1]
- or download this
$address{Bernd} = {
Name => 'Bernd Dulfer',
...
]
};
print 'Name: ', $address{Bernd}->{Name}, "\n";
- or download this
Name: Bernd Dulfer
- or download this
$address{Bernd}->{Books}->[3] = 'Goedel, Escher, Bach - An Eternal
+ Golden Braid';
- or download this
push @{$address{Bernd}->{Books}}, 'Icerigger';
- or download this
%authors = (
Tolkien => [
...
'Feet of Clay'
]
)
- or download this
$address{Bernd}->{Authors} = \%authors;
- or download this
push @{$authors{Tolkien}}, 'The Hobbit';
- or download this
#!/usr/bin/perl
...
$address{Bernd}->{Authors}->{Tolkien} = ['Silmarillion', 'Unfinish
+ed Tales'];
print Dumper(\%address);
- or download this
$VAR1 = {
'Bernd' => {
...
'Name' => 'Bernd Dulfer'
}
};
- or download this
#Short Name Str EMail Books
Bernd |Bernd Dulfer |Kapellenstr. 1 |bdulfer@sybase.com |(Lord of
+ the Rings|Hitchhikers Guide ...|The Color of Magic)
Bilbo |Bilbo Baggins |Bagend | |(The Red
+ Book)
- or download this
1: my %addresses;
2:
...
13: push @{$addresses{$short}->{Books}}, split /\|/, $books;
14: }
15: close ADDRESSES;
- or download this
foreach (@{$address{Bernd}->{Books}}) {
print $_, "\n";
}
- or download this
foreach (keys %{$address{Bernd}->{Authors}}) {
print $_, "\n";
...
print "\t", $_, "\n";
}
}
- or download this
Package Mod;
...
sub print_rubbish (
print "Rubbish!\n";
}
- or download this
%dispatch = (
insert => \&insert,
...
)
$dispatch{$token}->($query);