The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.
#!/usr/bin/perl

use strict;
use warnings;

use vars qw($foo);

$foo = 1;

print "Hello\n";

for my $idx (map { $_ * 10 } 1 .. 10)
{
    if ($idx > 17)
    {
        $foo = 2;
        print "Baz\n";
    }
}