#!/usr/bin/perl use strict; use warnings; my $whatever; if($whatever) { my $something = "here"; } else { my $something = "there"; } print "look I compiled $something\n"; __END__ Global symbol "$something" requires explicit package name (did you forget to declare "my $something"?) at Monks\Badcode.pl line 14. Execution of Monks\Badcode.pl aborted due to compilation errors. Process completed with exit code 255