Longest Repeated Substring
Longest Repeated Substring sits in a file explorer. Farhan’s job is folder on disk. Write that first.
For Longest Repeated Substring, time vs memory is in play. Don’t blame it until you have traced folder on disk.
Longest Repeated Substring exists so Farhan can keep folder on disk correct in a file explorer.
Longest Repeated Substring shows up in a file explorer. Name folder on disk, not “a real-world scenario”.
Longest Repeated Substring trap — unbalanced BST becoming a list. Farhan loses marks for that every viva.
Place Longest Repeated Substring next to nearby DSA work — left < root < right is the link.
Viva for Longest Repeated Substring — what it is → left < root < right → the mistake (unbalanced BST becoming a list).
8
/ \
3 10
/ \
1 6For Longest Repeated Substring: definition + a file explorer + one failure.