-f option is used to check whether the argument is a file or not.if (-f $ARGV[0]) { print "file"; } elsif(-d $ARGV[0]) { print "dir"; }
In reply to Re: how to check
by balakrishnan
in thread how to check
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |