22C:2 From CAT Scans to Google: Great Ideas in Computing
Homework 4. Due Thursday, September 28, 2006

  1. Write an algorithm for problem 5 on page 13 of Chapter 1 of Harel's book. Your "algorithm" does not need to look anything like computer code. Simply try to think of a clear step-by-step method to solve the problem, and write it down clearly and concisely.

  2. If we call the number of words in one of the books N and the number of words in the other book M, try to describe how the amount of time your algorithm requires grow with respect to M and N.

  3. Read Chapter 2 of Harel (at least read 27-40 and 50-53 and pay special attention to 36-40, "Elementary Computing Devices", since we'll carefully go over how Turing machines work in class next time).

  4. In Homework 5, you will use a Web-based "Turing Machine" simulator. For this homework, I simply want you to make sure you are working on a computer that can run the simulator. To get credit for this problem, you simply need to send me an email telling me whether the simulator appears to work on your computer or not .

    The simulator is here: Suzanne Britton's Turing Machine Simulator. It will work fine, without any additional set-up, on many machines around campus, as well as home/dorm machines, laptops, etc. Some machines might need an extra piece of software installed to enable it to work, however.

    TO DO: visit the simulator webpage (do this on your own machine or a machine in a campus lab/ITC where you are most likely to do your homework.)

    If it is working, you should see a screen like this. If this is the case, just send me email saying it appears to be working.

    If it is not working, describe the situation, as best you can in your email to me - including what you see on the screen, what kind of machine you're working on, where it is, etc. (If it doesn't, I'll help you fix it or find a computer that does work.)