how to use stl::map as two dimension array

前端 未结 3 655
感动是毒
感动是毒 2020-12-16 07:09

Could you let us know how to use stl:map as two dimension array? I wanted to access the individual elements as like mymap[i][j] where I do not know beforehand what the value

3条回答
  •  猫巷女王i
    2020-12-16 07:53

    Consider using a kd-tree instead. Each level of branching will compare the i an j values in turn. See http://en.wikipedia.org/wiki/Kd-tree.

提交回复
热议问题