When solving an algorithm problem in an interview: Restate the problem. Clarify input, output, edge cases, and constraints. Give a brute-force baseline. Identify the pattern: hash table, two pointers, ...