added part of maze solver