Question
A log viewer renders tabs with 4-column tab stops. Given a single line (no newlines), replace each tab with one to four spaces so that the character after the tab lands on the next multiple of 4 — counting columns from 0 over the output produced so far. All other characters occupy one column each. For example, 'ab\tc' becomes 'ab c' (two spaces bring column 2 to 4), and '\t' alone becomes four spaces.
expand_tabs(line: str) → str["ab\tc"]out"ab c"State your approach and its time/space complexity out loud before you optimize. Handle the edge cases (empty input, duplicates, overflow), and say why you chose this over the brute force. Green tests are the floor, not the grade.
Vibe coding: describe the solution in plain language (or narrate it) and the coach grades your approach. Generating runnable code from your description is coming next.