logic ? data structures how to
I have the following:

    String name, String word, String gold, String sack

I have to iterate through a log file and count the occurrence of each.

Dependencies: one name can have multiple occurences of word, gold, sack

How do i store it and increase count? (hash,arrays,lists,tables,class)[no databases]

    ex:log file

|name1|word1|gold1|sack1|00
|name1|word1|gold2|sack1|00
|name2|word1|gold1|sack1|00 
   


should result in

name1(2)--word1(2)--gold1(1),gold2(1)--sack1(2) 000
name2(1)--word1(1)--gold1(1)--sack1(1)    


i have tried this so far

class {string name;hashmap word;hashmap gold;hashmap sacks,int count;};
logic ? data structures how to
===

I have the following:

    String name, String word, String gold, String sack

I have to iterate through a log file and count the occurrence of each.

Dependencies: one name can have multiple occurences of word, gold, sack

How do i store it and increase count? (hash,arrays,lists,tables,class)[no databases]

    ex:log file

|name1|word1|gold1|sack1|00
|name1|word1|gold2|sack1|00
|name2|word1|gold1|sack1|00 
   


should result in

name1(2)--word1(2)--gold1(1),gold2(1)--sack1(2) 000
name2(1)--word1(1)--gold1(1)--sack1(1)    


i have tried this so far

class {string name;hashmap word;hashmap gold;hashmap sacks,int count;};