Perl Shell - A Solution

if (@ARGV) { ... }

Literally, this condition checks to see if there are any elements in @ARGV. If there are, the implication is that psh was given a script file. By the specifications of the assignment, we only want one file to be used as script input. Therefore, any further arguments must be arguments to that script file.

Recall: