Lesson 4: Sequences and secrets

Outline:

  1. Mini-quiz
  2. From last time: accumulating factorial example
  3. strings as sequences
    • Basic operations
    • split and join
  4. Exercises 1 + 2
  5. Other string methods
  6. Exercises 3 + 4
  7. Representing strings in computers
    • ASCII and Unicode, chr and ord
    • example: encoding/decoding messages
  8. Exercise 5

Reading assignment (to be completed by the next class):

  • Zelle sections 5.1-5.2 (pp. 129-136)
  • Zelle sections 5.4-5.5 (pp. 139-147)
  • Zelle section 5.7 (pp. 150-151)