a simple program for trying A* pathfinding algorithm