This emulates an Arduino algorithm which combines line following and left-hand maze solving.
Credit to MJRoBot - https://create.arduino.cc/projecthub/mjrobot/maze-solver-robot-using-artificial-intelligence-4318cf