sub autoSubmit{ print "Would you like the logs submitted? Y\\N?: "; my $autoSubmit = getInput; if ( (lc($autoSubmit) ne "y") and ($autoSubmit ne "n")) { print "You did not enter in Yes or No. Please try again\n"; $autoSubmit = autoSubmit(); } return $autoSubmit; }