This piece of code was written during a coding kata at JSCraftCamp 2018.
Rules: https://codurance.com/2017/10/12/functional-calisthenics/ Task: https://codurance.com/2017/11/16/katas-for-functional-calisthenics/#marsroverkata
- The set of instructions will be provided from the console
- Implement obstacle detection before each move to a new square. If a given sequence of commands encounters an obstacle, the rover moves up to the last possible point and reports the obstacle.
- If there was an obstacle, the mars rover will output the last position before the obstacle and a text saying an obstacle was found.