pathing.

new topic     » topic index » view thread      » older message » newer message

example of problem:

sequence maze = {
{5,5,5,5,5,5,5,5,5,5,5,5},
{5,0,0,0,0,0,0,0,0,0,0,5},
{5,0,0,0,0,5,0,0,0,0,0,5},
{5,1,0,0,0,5,0,0,0,0,0,5},
{5,0,0,0,0,5,0,0,0,9,0,5},
{5,5,5,5,5,5,5,5,5,5,5,5}}

How do I find a path to go from the 1 to the 9, avoiding all non-5 elements? 
(assume that there is only 1 1 and only 1 9, and their locations are known 
in advance)
=====================================================
.______<-------------------\__
/ _____<--------------------__|===
||_    <-------------------/
\__| Mr Trick

new topic     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu