In Lecture 4, students learn about solving a more complex recurrence relation by unwrapping. Gusfield also addresses the problem of counting inversions in a permutation.