/TuringMachine

Turing Machine Example

Primary LanguageJavaApache License 2.0Apache-2.0

TuringMachine

TuringMachine (Java)

Task 4. Applying SOLID principles

You have very poorly written Turing Machine code in TuringMachine.java . It works, but is hard to maintain and change

Your task is to apply as much SOLID principles as possible - chop code into pieces to make every class single responsibility: head, rules, tape, etc.

You might use any object oriented language.

You have *.tmprog.txt or *.tmprog.json files to execute by TM. Best proof of SOLID would be to demonstrate Turing machine that reads *.tmprog.txt files and then change it to be able to execute *.tmprog.json files from URLs by downloading them, loading and executing. If you did the design of program correct, these changes should be quite minimal.

Json files accessible via URLs:

https://rawgit.com/rgrisha/secureprog/master/tasks/task4/increment_dec.tmprog.json https://rawgit.com/rgrisha/secureprog/master/tasks/task4/running_ones.tmprog.json

Task URL: https://github.com/rgrisha/secureprog/tree/master/tasks/task4