in reply to Doubt in code - Beginner in perl
Glad you got your question answered. Just wanted to reiterate, welcome to the wonderful world of Perl.
You have truly chosen one of the most interesting and useful languages available!
I encourage you to check out perlrun to learn about some of Perl's many command line options.
These enable you to write very cool "one-liners" such as the following reproduction of your program:
perl -wlnE '$w{$_}++; END { say "$_ has appeared $w{$_} times" for sort keys %w }'
Happy coding!
πάντων χρημάτων μέτρον έστιν άνθρωπος.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Doubt in code - Beginner in perl
by Perl_Programmer1992 (Sexton) on Dec 30, 2018 at 18:48 UTC |