Discovering which parts of the brain are engaged when coding
news.mit.edu
news.mit.edu
It's only a chore when you can't envision the end result when everything falls into place and everything just works with zero/minimal bugs and the program behaves just as you imagined. This is the payoff moment we all should anticipate when coding, not seeing it as a 'chore' but as a sort of delayed gratification exercise where we reap what we sow.
For example, to start you spend 20m getting the local developer setup for that repo working because the docs are out of date, and then because the repo is rarely used another 45m updating node dependencies and wrangling webpack to satisfy new security warnings. Then 5 minutes of actual work: you add a new form field and update some CSS. Now wait 50 minutes for the CI to pass so you can merge your work.
No exaggeration -- these scenarios were common at my previous job.
Not sure whether my experience is common…. But maybe if someone feels like programming is a chore most of the time it’s a strong signal that they need to change the job and/or profession?
I still enjoy it occasionally on my own terms, but writing the kind of code that people would pay me to write is mostly dreadful at this point. I’ve seen it all before and the problems aren’t interesting enough to keep me motivated.
Which is why I’m shifting into project management.
I still remember the excitement I felt in the beginning though, where every piece of code was a new adventure.
My point is, things change with time and experience.
Wouldn't that indicate a state of flow, meaning that you are in the 'zone'?
"Neural correlates of interspecies perspective taking in the post-mortem Atlantic Salmon: An argument for multiple comparisons correction" - https://www.scinapse.io/papers/2043045839
> What the group wanted to find out was whether the brain signals seen in their study when participants were examining pieces of code resembled the patterns of activation observed when neural networks analyzed the same piece of code. And the answer they arrived at was a qualified yes.
Does this allow meaningful conclusions? I have difficulties to decide whether the article tries make a statement or tries to promote a hypothesis.
But it's been an area with slow progress. Some of the debates about how e.g. face detection works are debates that were going on when I took brain science in the late 70s. That's one reason why so much of the AI community has basically punted to just machine learning.
"Take, for instance, a loop ..."
Personally, I write most programs in a logic programming language that has no loops. I wonder whether the engaged brain areas also depend on the programming language. The previous study used for example Python, an imperative language, and mentiond "Language system responses during code comprehension are weak and inconsistent":
https://elifesciences.org/articles/58906
Could it be that language system responses are stronger for more declarative programming languages, where a clear description of the problem is of greater importance?
It takes similar logical skills like:
- Not knowing end result/solution of an equation
- Performing multiple operations to solve different parts of an equation
- Crafting an equation to match the observation (similar to writing a logical program to achieve a certain end result)
- Dealing with constants that never change
When I'm programming, I often start tackling a complicated function (I do ML and numerics) without knowing the logic 100%. I just let my instinct guide me and I stumble little by little onto the solution with the help of the compiler. You can do the same process with math, but the mental strain required is orders of magnitudes more because you need to actually do the math yourself.
I would however expect similar fundamental brain functions to be at play. For debugging and instinct driven tasks, I would co-relate that with hit-and-trial methods for solving equations or validating equation formulations.
Some of you know that I am going through a process where after getting my ADHD under control with nootropics in that I am now basically re-applying computer programming and re-learning it.
It would seem since I am taking lion's mane which does rebuild connections between short term and long term memory via BNDFs that might be a short term and long term memory connection beyond just the areas that are active when coding.
In my own case my understanding of other's coding and my own has drastically improved. I am getting close to seeing actual code structures by just reading the code which I could not do before.
Has anyone participated in an fMRI study? I'm curious how they do this in such a large machine.
I've been interested in conducting ECG based studies at scale on people as they learn activities, but the equipment available (mindwave neurosky type headsets) is somewhat primitive.
Not for this specifically but I've done other fMRI studies and I bet they could get you to read code samples and answer multiple-choice questions about it by telling the researcher A, B, C, or D. e.g. "what would be the output of these 12 lines of javascript?" etc. Or you could probably even select a multiple-choice from the screen by sliding a selection thing up and down over the options and then pressing the trigger for enter (so like, there's a joystick + trigger that you hold in your right hand)
Also rubber ducking is a pretty social exercise, even if no one is there.