Features/Perl5Debugger: test.pl

File test.pl, 690 bytes (added by bowtie, 2 years ago)

test.pl

Line 
1#!/usr/bin/env perl
2
3use 5.010;
4use strict;
5use warnings;
6
7# Turn on $OUTPUT_AUTOFLUSH
8$| = 1;
9
10# use diagnostics;
11# use Data::Printer { caller_info => 1, colored => 1, };
12
13say 'START';
14
15foreach (0..7)
16{
17 my $line = $_;
18 last unless defined $line;     # exit loop if $line is not defined
19 print "$_ : $line \n";
20}
21
22my %HoH = (
23    flintstones => {
24        husband   => "fred",
25        pal       => "barney",
26    },
27    jetsons => {
28        husband   => "george",
29        wife      => "jane",
30        "his boy" => "elroy",  # Key quotes needed.
31    },
32    simpsons => {
33        husband   => "homer",
34        wife      => "marge",
35        kid       => "bart",
36    },
37);
38
39say 'END';
40
411;
42
43__END__