in reply to Keeping variable persistent

# Parent script $ENV{FOO} = "Hello, world\n"; # Child script print $ENV{FOO};
But don't do that.

Instead learn how to write functions and libraries, and then learn why globals are officially a Bad Idea.