Comment by zemvpferreira
10 months ago
The objective in an interview like this shouldn't be to grade the quality of the code you bring in any sort of scale, but to have a discussion about the options you took. In that sense, it really matters very little what you present as long as we can do a small back-and-forth that lets me into what sort of person you are.
> but to have a discussion about the options you took
I can clearly state that this is not I commonly think about code that I write privately (and also for code that I write for the job only if I must). For private code, I rather commonly start with a "gut feeling" about some unexpected symmetry that the problem that I am working on likely has, then try to formulate these "gut feelings" as mathematical properties, and later theorems. At the end, everything "fits (for outsiders: unexpectly) together".
Thus, there is hardly ever a "option that I took", but rather a "I let everything flow: from the source [my gut feeling] to the sea [which is - ironically - the source (code)]".