News for hackers. Stuff that matters.
Re:Code Smells: Iteration by jnty on Wednesday August 23, 2017 @11:28AM (#15082257)
I guess - but I feel like you'd call it an "error" rather than a "smell". Better to just teach people data structures rather than which constructs they should be afraid of. Approaching it "sideways" like this just leads to people going "I heard that loops can be bad, so I copied and pasted that line 25 times instead".
Re:Code Smells: Iteration by jayd16 on Wednesday August 23, 2017 @11:52AM (#15082500)
Its a smell and not an error because it works perfectly fine and it actually is perfectly fine for now because the n for that linear search is low.