3 ms·
If you want to reason about code, why not give them the solution and ask them how they would implement it - discussing with them about how they would implement
by athreya86 11y ago
If you want to reason about code, why not give them the solution and ask them how they would implement it - discussing with them about how they would implement the solution would be more enlightening. When you are being interviewed, the first hurdle is 'solving' the problem - coming up with a solution. Evaluating a developer on 'how they solve' a problem in highly stressful situation seems somewhat unreasonable - after all, what is more important in their day-to-day job is the ability to write maintainable, easy-to-understand code. In real life, problems are often solved via brainstorming with the team, going through iterations of getting/clarifying requirements
- ericlippert 11y agoI agree; a problem I often give -- which I will discuss on my blog next week -- is "here's an existing solution to a problem, it is full of security holes and bad programming practices, describe to me some techniques you would use to fix this code without changing the public interface". That's problem people face in real-world development all the time: bunch of code, works when callers are benign, badly broken when callers are hostile, the client has shipped so we can't change the interface, fix the problem.