Please also supply your answer to the following questions:
- What is the complexity of your algorithm (in big O notation)?
- How would you improve your algorithm?
- How would your adapt your algorithm to three dimensions? How would that affect the complexity?
Responses:
- unknown
- create a strategy to group pairs with proxyity indice (x + y diff) compared to a pair
- we have for now a 100x100 = so 10000 possibles positions.
- if we create a cube (100x100x100) there is 1000000 possibilities of position. so if we add z indice on Position and Grid, the issue will be the charge due to the search of position for a vessel on the grid.
Have a good code reading :)
you can try make core.tests