Finally understood array methods with a 30-minute whiteboard session
I was stuck on map, filter, and reduce for like 2 weeks. Kept reading tutorials and watching videos but it just wouldn't click. Yesterday I grabbed a whiteboard and drew out a tiny array of 5 numbers, like [3, 8, 1, 9, 2]. I traced each method step by step, writing what map does to each item and what filter keeps. Then I wrote a small loop that does the same thing and compared them side by side. Suddenly it all made sense. Has anyone else found drawing things out helps way more than any course? What other topics should I try this trick on next?
Wait, you struggled with map, filter, and reduce for two whole weeks? That's wild to me because those are the first things that made sense in JavaScript. But the whiteboard thing is genius, honestly. Drawing out the loop side by side with the method is the key, that's how you actually see what's happening under the hood. Tracing data by hand forces your brain to slow down and notice the pattern, videos just let you zone out. You should try this with recursion next, or maybe closures. Those are the ones where people usually stare at the screen for days. Just draw a tiny function calling itself and watch it unroll on paper, that's the moment it clicks.