Dear Paula,
actually the equivalent to
$hash{'A'} = $hash{'A'}+1;
is
$hash{'A'}++;
The reason why your expression
$hash{'A'} = $hash{'A'}++;
did not work has to do (IMHO) whit the way it is executed
First the subexpression
$hash{'A'}++
is evalueted, which increments the value of $hash{'A'}
> I'm having a horrendous time trying to write to cells in my spreadsheet
that
> are specified by variables.
>
> I'm trying to write like this:
>
> $active_sheet -> Cells ($set, ($loop + 24)) -> {Value} = ("$loop");
> $active_sheet -> Cells (($set + 1), ($loop + 24)) -> {Value} = ("some
> text");
>
> :)
> All three of those modules are in our 5.8 repository at
> http://theoryx5.uwinnipeg.ca/ppms/, which you can access
> by setting the repository within the ppm shell to
> http://theoryx5.uwinnipeg.ca/cgi-bin/ppmserver?urn:/PPMServer58
> The GD module is version 2.05, and includes jpeg and fr
On 12/14/2002 10:02 AM, Bill Royds -Perl wrote:
The key is
$count = () = $string =~ /a/g;
Which creates a list context for return of match operator $string =~/regex/g
Then the $count= is asking for a scalar context return of a list, which we all know returns the count of elements in list.
The
The key is
$count = () = $string =~ /a/g;
Which creates a list context for return of match operator $string =~/regex/g
Then the $count= is asking for a scalar context return of a list, which we all know
returns the count of elements in list.
The expression
$count = (@temp) = $string =~ /a/g;
On 14.12.2002 11:57 Uhr, "Adrian Brinton" <[EMAIL PROTECTED]> wrote:
>
> #count the occurrences of "a"
> $string = "aaabbbcccddd";
> $count = () = $string =~ /a/g;
> print "Count is $count\n";
>
This is really cool ! I never ever seen this kind of line. Is there any rule
or document snipe or exp
I found this bit of code somewhere, and I've used it whenever I need to
count occurrences of something. It doesn't require any extra temp variables.
It works although I don't know why. Perhaps someone can explain exactly
what's happening here...
#count the occurrences of "a"
$string = "aaabbbcccd
Harald Wopenka wrote:
Hi there!
I wanted to watch the communication between browser and server and found
that nice ProxyMod-Module. But for some reason it doesnt work.
This is the code:
use Net::ProxyMod;
$p = Net::ProxyMod->new("172.16.3.1", 8080, "", 0, 1);
$p->get_conn(\&infunc,\&outf