in reply to find out, if perl is started with the -c switch

check man perlvar
perl -c -e 'BEGIN { print "started with -c\n" if $^C }' perl -e 'BEGIN { print "started with -c\n" if $^C }'

Replies are listed 'Best First'.
Re^2: find out, if perl is started with the -c switch
by borisz (Canon) on Sep 23, 2005 at 09:39 UTC
    Thanks, thats exactly what I searched for!
    Boris