Given a n*n grid with free spaces and obstacles in the form an n*n integer matrix. We need to find shortest between any two given points (x1,y1) and (x2,y2) through the free spaces. We are not allowed to move in diagonal. Please help me figuring out an algorithm for doing this.
Thanks in advance.
ajhais
0
Newbie Poster
Recommended Answers
Jump to PostGiven a n*n grid with free spaces and obstacles in the form an n*n integer matrix. We need to find shortest between any two given points (x1,y1) and (x2,y2) through the free spaces. We are not allowed to move in diagonal. Please help me figuring out an algorithm for doing …
Jump to PostHi.. thanks for the solution. I was thinking of going with the same.. How can we approach this problem if the map is dynamic.. that is if some obstacles can randomly appear in the map.. We actually need to code a bot for battle city game..
Well if you know …
All 7 Replies
csurfer
422
Posting Pro
ajhais
0
Newbie Poster
csurfer
422
Posting Pro
nucleon
114
Posting Pro in Training
csurfer
422
Posting Pro
nucleon
114
Posting Pro in Training
Prabakar
77
Posting Whiz
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.