Assignment 2 due date + review topics

Assignment 2 due date

First off, I’ve decided to push back the due date for Assignment 2 until Saturday 118 at 5pm. Note that the content of the assignment is still fair game for the quiz, but this way you can decide a little better how you want to spend your time. (Also, I’ll be on a plane Friday night and with my husband+toddler Saturday, so I can’t guarantee quick responses to any emails or Piazza posts at those times.)

Review topics

Also, today we talked about some review topics. These span the book chapters 1-3 and 5 (except 5.8-5.9), as well as sections 11.2.1-11.2.2. Here is the list:

Python topics:

  • print
  • input
  • range
  • for, in
  • int, float
  • +, -, *, /, //, %, **
  • abs()
  • round()
  • import
  • math and random libraries
  • def main():
  • str and list
  • +, *
  • [] (“indexing”)
  • [:], [::] (“slicing”)
  • len
  • <str>.split(<string>)
  • <str>.join(<list>)
  • <list>.append(<element>)
  • <seq>.index(<integer>)
  • other string and list methods

General CS topics:

  • compiler vs. interpreter
  • parts of a program
    • comments (#)
    • keywords (for, in, def, and other things that IDLE turns orange)
    • literals (strings, integers, floats)
    • identifiers (variables names, function names, etc.)
    • expressions (using operations like +, *, etc.)
    • function calls (like chr(<integer>) or round(<number>))
    • assignment statements (<identifier> = <some expression>)
    • simultaneous assignment (x, y = y, x)
  • importing libraries
  • binary
  • accumulator pattern
  • Unicode
  • two types of for loops to iterate through a sequence
  • mutability (lists: yes, strings: no)
  • pseudo-randomness
  • encoding (Caesar ciphers)