3 ms·
I'm terrible at right brain thinking and I've been chugging the functional kool-aid, so I don't think that's the issue. In fact, I could almost argue the oppos
by rprospero 15y ago
I'm terrible at right brain thinking and I've been chugging the functional kool-aid, so I don't think that's the issue.
In fact, I could almost argue the opposite. For instance, a standard left brain approach is to break a large problem into smaller sub problems which can be easily managed. When I'm doing functional programming, it's easy to start breaking down a problem via recursion, but the idiom for imperative programming is often to tackle the whole problem at once. To me, that seems to require far more pattern recognition and gestalt understanding than the reductionist functional approach.
- ankurdhama 15y agoHmmm .. in imperative you start from one step and keep on thinking of next step and so on until you reach solution. This is more like left brain. In FP you break down the whole problem into parts but at the same time you also look at the overall problem and the you think about various composition to solve specific parts and how this evolve in complete solution, which for me seems like more of a right brain thing to come up with correct composable parts and how to glue them together to find the solution
- rprospero 15y agoI see where you're coming from. I guess my argument comes from your statement in imperative you start from one step and keep on *thinking of next step* I'd argue that the thinking there is far more right brained that the thinking in functional programming. When I'm doing functional programming, the steps are large enough that there's usually only one step I can take which won't go off into a horribly wrong direction. With imperative programming, the steps are much simpler, but also much smaller, so I can't think of just one step at a time. Instead, I need to think ten steps ahead, which feels like the kind of pattern matching that the right brain does.
- ankurdhama 15y agoMy point was that in FP you build things by composing existing things which require much more thinking it terms of trying different permutation and combinations at which the right brain is much more capable of. In general when I am doing FP I need to do lot of thinking and it requires some time whereas in imperative programming you can basically start coding as soon as you heard the problem. Ofcourse in the end the FP solution is much more elegant and simple