# Lesen open my $fh, '<', $filename or die "$filename: $!\n"; # ... close $fh; # Schreiben open my $wh, '>', $filename or die "$filename: $!\n"; print $wh "Hello World\n" or die "print to $filename: $!\n"; close $wh or die "close $filename: $!\n";