in reply to Question about ++ and hash value

It's counting the number of times a given line appears in a file. $hash{$line}++ is incremented by 1 (set to one automagically on the first instance of $line) each time $line (well, $line minus the piece removed by chop) appears.


emc

Information about American English usage here and here.

Any Northeastern US area jobs? I'm currently unemployed.

Replies are listed 'Best First'.
Re^2: Question about ++ and hash value
by ada (Novice) on Dec 09, 2007 at 00:37 UTC
    Ok thanks so are these increments stored as values of keys? Ada x

      Yes


      emc

      Information about American English usage here and here.

      Any Northeastern US area jobs? I'm currently unemployed.