Course of Raku / Essentials / Control flow essentials / Code blocks / Lexical scope
Quiz — Lexical scope
What does this program print?
my $a = 1;
my $b = 2;
{
my $a = 3;
$b = 4;
my $c = 5;
}
my $c = 6;
say "$a$b$c";| 146 | Output of the program: (: 125, 126, 145, 146, 325, 326, 345, 346 :) |
Course navigation
← Lexical scope | Global variables →
Translations of this page: English • Deutsch • Español • Italiano • Latviešu • Nederlands • Български • Русский • Українська