Universal Turing machine simulator in python