In a previous exercise you wrote a turing machine simulator. In this exercise, you are challenged to write a program for the turing machine that performs multiplication. Write a program that takes an input like _ _ _ [1] 1 1 * 1 1 1 1 _ _ _, which indicates the multiplication 3 × 4, and writes the output _ _ _ 1 1 1 1 1 1 1 1 1 1 1 [1] _ _ _.

Advertisement

Pages: 1 2