checkit("-e,-w", "c:\\myfile.txt"); checkit { if($_[0] && $_[1]) { if($_[0] $_[1]) { #Here exists the Problem the interpreter always displays me an error message print"File exists"; } else { print"File doesnt exist"; } } }