Is there any unit, or built in functionality, to do the equivalent of perl's associate arrays or Python's dictionaries?

What I am trying todo is to parse some lines and to store ocurrences of certain strings.

For example
string1
string2
string1
string3
string2

What I want to do is to create an entry string1 and count all string1 one ocurrences, the same for each different string. In the end I would have
string1 2
string2 2
string3 1


_______________________________________________
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Reply via email to