cs3110 / textbook

The CS 3110 Textbook, "OCaml Programming: Correct + Efficient + Beautiful"
Other
740 stars 134 forks source link

fix typo, define n in party optimization problem #60

Closed SanjitBasker closed 2 years ago

SanjitBasker commented 2 years ago

The text says that there are 2n possible invitation lists, but naively there are 2^n invitation lists, one for every subset of the employees.

The phrasing is also somewhat ambiguous--is O(n * 2^n) considered "exponential time"? since the validity check and fun value of each possible invitation list take O(n) time to compute.