Shortest Path Finding in Mazes by Active and Passive Particles