But this code doesn't compile...
karls-mac-mini:playground karl$ perl -c ./choroba.pl Global symbol "$max_count" requires explicit package name (did you for +get to declare "my $max_count"?) at ./choroba.pl line 14. Global symbol "$sum" requires explicit package name (did you forget to + declare "my $sum"?) at ./choroba.pl line 14. Global symbol "%count" requires explicit package name (did you forget +to declare "my %count"?) at ./choroba.pl line 14. Global symbol "$sum" requires explicit package name (did you forget to + declare "my $sum"?) at ./choroba.pl line 14. Global symbol "%count" requires explicit package name (did you forget +to declare "my %count"?) at ./choroba.pl line 14. Global symbol "$max_count" requires explicit package name (did you for +get to declare "my $max_count"?) at ./choroba.pl line 14. Global symbol "$expression" requires explicit package name (did you fo +rget to declare "my $expression"?) at ./choroba.pl line 16. Global symbol "$sum" requires explicit package name (did you forget to + declare "my $sum"?) at ./choroba.pl line 16. Unmatched right curly bracket at ./choroba.pl line 17, at end of line syntax error at ./choroba.pl line 17, near "}" ./choroba.pl has too many errors.
Update: It compiles. I copied the code from the download link into an emacs buffer as i did it many thousand times before. For some unknown reason the result was broken. I never observed this before. I'm very sorry. And to be honest: I couldn't hardly imagine that choroba should have posted something that doesn't compile.
Best regards, Karl
«The Crux of the Biscuit is the Apostrophe»
perl -MCrypt::CBC -E 'say Crypt::CBC->new(-key=>'kgb',-cipher=>"Blowfish")->decrypt_hex($ENV{KARL});'Help
In reply to Re: Sum to 100 at Rosetta Code
by karlgoethebier
in thread Sum to 100 at Rosetta Code
by choroba
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |