#!/usr/bin/perl -w use strict; my $file="h.txt"; open (my $fh, '<', $file) || die qq[Kann Datei "$file" nicht öffnen ($!)\n]; while (my $line=<$fh>) { chomp($line); print "====> $line <====\n"; } close ($fh);