Thread Filelist: Dateien öffnen
(39 answers)
Opened by INIING at 2012-07-05 14:14
wo haperts denn?
zeig doch mal code. Code (perl): (dl
)
1 2 3 4 5 6 7 8 my @files = qw( /foo/bar.txt /foo/boo.txt ); for my $file (@files) { open my $fh, "<", $file or die "Could not open $file: $!"; # tu was mit $fh } Always code as if the guy who ends up maintaining your code will be a violent psychopath who knows where you live. -- Damian Conway in "Perl Best Practices"
lesen: Wie frage ich & perlintro brian's Leitfaden für jedes Perl-Problem |