StudyGraph
Algorithms & Complexity Don't do this

3 Big-O mistakes that cost you marks

3 mistakes that cost marks in Big-O questions

Lesson notes

Key points

Takeaway: Drop constants, multiply nested loops, draw recursion trees.

Quick check: What is the time complexity of two nested loops each running n times?
  1. O(2n)
  2. O(n²)
  3. O(n log n)

Inner loop runs n times for each of n outer iterations: n × n.

Lessons like this, for your syllabus.

Short narrated study videos written for your course, level and exam. Free to start.

Get lessons for your own syllabus