3 ms·
Uh, knowing when to use a hashmap, recursion and a loop is not a puzzle. It's table stakes.
by VirusNewbie 2y ago
Uh, knowing when to use a hashmap, recursion and a loop is not a puzzle. It's table stakes.
- johnnyanmac 2y agoNo, but "failing" because you didn't use map.emplace instead of map.insert on a test that didn't let you look up documentation and you code in 4 other languages is definitely approaching gatekeeping instead of problem solving. Nevermind that the parameters for STL maps are convuluted to begin with if you're not using them everyday.
- zelphirkalt 2y agoWhich is different though from LC being overly specific about how long you solution is allowed to take and how much memory etc.
- simonbarker87 2y agoOf course, and nothing in my comment suggests otherwise. You’ve highlighted tools and techniques that can be used to solve problems and puzzles. I don’t enjoy drawing for the sake of it but I’m happy to draw a sketch for a home layout or woodworking project, both require me to be able to use a pencil, but one I will do well in the other I would fail at. My point is that there are far better ways to test that than LC. My favourite interviews have been “here’s a real problem, placed in context, how would you solve it?” And “here’s an app with a handful of bugs, please fix it”