First script with main function
examples/perl-intro/hello_world_main.pl
#!/usr/bin/env perl use v5.10; use strict; use warnings; sub main { say 'Hello World'; } main();
- Putting all your code in small(!) functions will make your code better.
#!/usr/bin/env perl use v5.10; use strict; use warnings; sub main { say 'Hello World'; } main();