![]() |
|
XP is just a number | |
PerlMonks |
Re^5: Entity statisticsby choroba (Cardinal) |
on Nov 12, 2024 at 13:23 UTC ( [id://11162658]=note: print w/replies, xml ) | Need Help?? |
> As the variable $tally is defined beforehand and preceded by the keyword "my", I don't understand what is wrong. How could I fix this? The scalar variable $tally is different to an array variable @tally. Single members of the array are called with a dollar sign followed by a square bracket, but they are still elements of the array @tally. So, you need to declare the array:
> How could I get rid of "(?^:" and ")"? One possibility is to use a regex:
> Would it be possible to save this output to a file? The easiest way is to use redirection in your shell, it should work even in MSWin.
If you want to write to a file from within Perl, open a file for writing and print to it:
map{substr$_->[0],$_->[1]||0,1}[\*||{},3],[[]],[ref qr-1,-,-1],[{}],[sub{}^*ARGV,3]
In Section
Seekers of Perl Wisdom
|
|