How to take computer science lecture notes on iPad

Type the code, draw everything else. Here is a note system that matches how CS exams actually test you.

By the Edition teamUpdated 5 min read

Is an iPad worth it for CS notes?

CS students disagree, and both sides have a point. From one thread: "typing is much better for CS notetaking, because you'll want the ability to move text and diagrams between PDFs, webclips, IDEs, and your notes," and from the same thread, "my DSA class has plenty of visual (object) diagrams" (r/csMajors, 8 Mar 2023).

Both are right. Intro programming lectures are mostly code, so a laptop wins there. Data structures, discrete math, algorithms and architecture are mostly diagrams, traces and proofs, and handwriting wins there.

How CS exams usually work

Many CS exams are written on paper with no computer. Expect to trace what a piece of code prints, write a short function by hand, draw a linked list or tree after a sequence of operations, and give a Big-O runtime with a reason. Discrete math adds proofs.

Some courses allow a one-page cheat sheet and some allow nothing, so check the syllabus. The skill gap is predictable: students who only ever write code with autocomplete and a run button find it hard to write correct code on paper.

Where CS students get stuck

  1. Recursion. Following the calls down and the return values back up. It only clicks when you draw the call stack.
  2. Pointers and references. What changes when two variables refer to the same object. Box-and-arrow memory diagrams are the fix.
  3. Runtime of nested loops. Counting how many times the inner loop runs, especially when its range depends on the outer loop.

A page layout for CS lectures

Keep the lecture slides in view and split your page into three zones:

  • Code: the snippet from the slide, copied small or typed. Do not rewrite long code by hand. It is already in the slides.
  • Trace: a table of variable values, one row per step, or a stack of call frames.
  • Picture: the memory diagram, tree or array, drawn after each operation.

Dot or grid paper keeps arrays and tree levels straight.

Worked example: trace a recursive function by hand

def mystery(n):
        if n == 0:
        return 0
        return n % 10 + mystery(n // 10)
        print(mystery(472))

Draw one box per call, stacked downward:

  1. mystery(472): 472 % 10 is 2. Waits on mystery(47).
  2. mystery(47): 47 % 10 is 7. Waits on mystery(4).
  3. mystery(4): 4 % 10 is 4. Waits on mystery(0).
  4. mystery(0): base case, returns 0.

Now go back up: 4 + 0 = 4, then 7 + 4 = 11, then 2 + 11 = 13. It prints 13. The function adds the digits. Four calls for a three-digit number, so the runtime grows with the number of digits, which is O(log n).

A second quick one, on runtime:

for i in range(n):
        for j in range(i, n):
        count += 1

The inner loop runs n times, then n − 1, down to 1. That sum is n(n + 1)/2, so for n = 10 it runs 55 times. The leading term is n²/2, so it is O(n²). Check yourself by running it with n = 4 (10 iterations) and n = 10 (55).

A weekly routine for a CS course

  • After each lecture: re-trace one example from the slides by hand, without looking at the output.
  • Once a week: write one function from the problem set on paper, with no editor. Then type it in exactly as written and run it. The bugs you find are the ones you would make on the exam.
  • Before the exam: take a posted past exam on paper, timed. Type up your code answers and run them to check the logic. For tracing questions, a visualizer such as Python Tutor shows each step so you can compare it with your hand trace.

Where Edition fits

Edition keeps each course in its own folder and opens the lecture slides in a pane beside your page, so the code stays readable while you draw the trace next to it. Dot and grid paper are built in, and a typed page is there when a definition or snippet should be text.

Lasso a trace and choose Check my work to have it point at a mistake. That needs a connection, and it is not a grade. Before the exam, Practice exam opens a posted past exam with the key hidden and an optional timer. Edition does not grade it, and it does not run code. Keep your editor for that.

Other ways to do it

  • Laptop for everything, plus a paper notebook for traces and diagrams. Cheap and it works.
  • Markdown notes in a code editor, with diagrams as photos of paper sketches.
  • A whiteboard for recursion and tree problems with a study partner, then a photo for your notes.

Common questions

Should I handwrite or type computer science notes?

Type code you will run. Handwrite traces, memory diagrams, trees and proofs. Exams on paper test the handwritten skills, so practice them that way.

How do I study for a CS exam that is on paper?

Write functions by hand without an editor, then type them in exactly as written and run them. Trace code by hand and compare with the real output. Take past exams on paper under time.

Is an iPad worth it for a CS major?

It is most useful in data structures, algorithms, discrete math and architecture, where notes are diagrams and proofs. For intro programming lectures that are mostly code, a laptop does more.

Can Edition run or check my code?

No. Edition is a notes app. Lasso Check my work can point at a mistake in a handwritten trace, with a connection, but it does not run code or grade anything.

Keep reading