my $path; # if an argument was passed, use it if (@_) { $path = shift } # otherwise, use "." else { $path = "." }