Homework Assignment Number 1

  1. Install Python 3 for home computer or laptop (preferred) unless you plan on only using the lab computers. Follow the website's instructions for Windows or MAC operating systems.
  2. Load the program IDLE, the interactive program for running Python and test it. Do variations on the following, just to make sure you can get IDLE to work (Do not hand this in):
    1. 2 + 2
    2. 3 - 1
    3. print(3 - 1)
    4. print('Hello World')
  3. Read the 1st chapter of  the Donaldson book
  4. Write a simple algorithm using pseudo code or a flow chart (similar to the PBJ algorithm). Only write one algorithm with the purpose of showing that you understand what an algorithm is. Some examples of algorithms you could write:
    1. Preparing a specific non-alcoholic or alcoholic mixed beverage: chocolate milk, ice cream soda, Martini, ...
    2. Preparing a bowl of cereal with milk or fruit
    3. Instructions for gluing sticks on a piece of paper to make a stick figure
    4. Building a house out of blocks
Grading Criteria of Algorithm (4 above):
  1. Is your description adequate? Would an idiot (a robot or
    computer) be able to follow your instructions?
  2.  Does the algorithm make choices? Are steps repeated?
    – For example, the PBJ algorithm keeps checking if there is
    enough peanut butter. If there is enough the algorithm
    advances, if not it repeats the process. [Here there is a
    choice and a repeat]
  3.  Cleverness, innovation, creativity is worth more points
  4. More detail is worth more points.