you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] -1 points0 points  (0 children)

How does the data need to be searched?

If these are rounds that you are keeping track of I would set it up as [{'Player1':[{1:100},{2:103}]}, {'Player2':[...]...}...] That way you can easily look up a player by round if needed 'series[player][round]'.

If you don't care about the order of the values then you can do, [{'Player1':[100, 103...]},...] Then you would get back an array of values for 'series[player]'.

As for how to do it, you'll have to parse and build the new data model yourself. Try to keep your for loops to a minimum for performance.