• Summary

    The goal of this course is to read through Brian Kernighan and Rob Pike's book "The Practise of Programming" and thereby gain an understanding of techniques that make individual programmers more effective and productive.

    IMPORTANT: I've been told that the summer session technically starts on June 1, 2006, and students are still choosing sections. In view of this, it seems I'll have to push the due dates out a bit. I haven't decided yet, but the first HW will likely be due June 7.

  • Contacts:

    • Email: adnan AT [ ece DOT utexas ANOTHER DOT. edu ]

      IMPT Put POP in the subject line to ensure my spam filter doesn't drop your mail.

    • Phone: 512 475 9774 (I'm in sporadically, and don't check voice mail regularly.)

  • Text

    There is an official website for the book, but Kernighan and Pike maintain a far superior site, which includes source code for examples.

    Kernighan teaches a class based on the PoP text; he has links to some wonderful readings.

  • Format/Evaluation:

    I will assign 9 assignments consisting of exercises from PoP. The homeworks will not be programming intensive-their goal is to make you read PoP in an organized manner.

    Grades will be assigned on the basis of performance on the homework.

  • Assignments:

    • Assignment 1: Read Chapter 1 and turn in answers to questions 1-1, 1-2, 1-4, 1-5, 1-6, 1-7, 1-9, 1-11. (For 1-6, do only the first part, i.e., don't experiment with different compilers.) Solution

      Some comments on Chapter 1.

      Star credit: Comment a given C library that implements a bitvector type in the doxygen style. Details: Star 1

      Due June 7.

    • Assignment 2: Read Chapter 2 and turn in answers to questions 2-2, 2-3, 2-5, 2-6, 2-9, 2-12, 2-14, 2-16. (For 2-9, implement it in C only.) Solution 1, Solution 2,

      Some comments on Chapter 2.

      Star credit: Write code to group the vertices in an undirected graph into two disjoint sets A and B of equal size while minimizing the number of edges that have one endpoint in A and one in B. Apply your algorithm to the given examples. Details: Star 2

      Due June 18.

    • Assignment 3: Read Chapter 3 and turn in answers to questions 3-2, 3-3, 3-5, 3-6. Solution

      Some comments on Chapter 3.

      Due June 25.

    • Assignment 4: Read Chapter 4 and turn in answers to question 4-8, and write a critique of the CSV library implementation in Section 4.2, and how the implementation in Section 4.3 addresses your critique. Solution

      Some comments on Chapter 4.

      Due July 2.

    • Assignments 5/6: Read Chapters 5 and 6. For each piece of questionable code in Section 5.2 and 5.4, explain what's wrong with it. Turn in an answer to question 6-1. Read the extreme programming view of testing at http://www.extremeprogramming.org/rules.html and critique it. Solution

      Some comments on Chapter 5-6.

      Due July 9.

      Star credit: Write a set of tests for a generic array package that will be provided. Details: Star 3

    • Assignment 7/8: Read Chapters 7 and 8. Describe the steps K&P took to improve the performance of the spam filter example in Chapter 7. Turn in an answer to Exercise 7-3. For each piece of questionable code in Chapter 8, write a 1-3 sentence explanation of what's wrong with it. (There are 15 instances of questionable code; you don't have to copy out the entire listing.)

      Some comments on Chapter 7-8.

      Star credit: You will be provided code implementing hashing, and will be required to identify the performance bottlenecks in the code. Details: Star 4

      Due July 23.

    • Assignment 9: Cancelled: Read Chapter 9, and turn in answers to 9-1, 9-3, 9-9, 9-18. New assignment: Reach Chapter 9 and write a summary of what you learned - 1 to 3 paragraphs per section. Some comments.

      Due July 30.

  • Useful links:

    • Discussion on development tools

    • Michael Ogg's talk on software startups

    • Michael Ogg's wonderful Minitutorial on C++

    • The glu library

    • Lampson's classic paper on System Design

    • An article on how to be a programmer from Ujjwal Sarin, UT ECE 2003, now at Microsoft.