at test.pl
#!perl
use strict;
my $filename ='/home/v-guhe/tmp/abc.txt';
if(-e $filename)
{
print "file $filename exist\n";
}
else
{
print "file $filename no exist\n";
}
BASH-/home/v-guhe/tmp %perl test.pl
file /home/v-guhe/tmp/abc.txt exist
BASH-/home/v-guhe/tmp %
#!perl
use strict;
my $filename ='/home/v-guhe/tmp/abc.txt';
if(-e $filename)
{
print "file $filename exist\n";
}
else
{
print "file $filename no exist\n";
}
BASH-/home/v-guhe/tmp %perl test.pl
file /home/v-guhe/tmp/abc.txt exist
BASH-/home/v-guhe/tmp %