Decision tables: Difference between revisions
m
→{{header|Perl}}: use v5.36
Thundergnat (talk | contribs) m (syntax highlighting fixup automation) |
SqrtNegInf (talk | contribs) m (→{{header|Perl}}: use v5.36) |
||
Line 1,664:
=={{header|Perl}}==
<syntaxhighlight lang="perl" line>use
sub decide($q,$a) {▼
▲sub decide {
▲ local *a = shift;
▲ my $bit;
▲ my $cnt = 1;
for my $prompt (@q) {
print "$prompt: ";
Line 1,690 ⟶ 1,688:
'Printer does not print',
);
my %answers = (
0b00100000 => 'Check the power cable',
|