Variable "$x" will not stay shared at foo.pl line 9.