Live data from Hacker News

To the brain, reading computer code is not the same as reading language

news.mit.edu

101–110 of 232 posts

Re: To the brain, reading computer code is not the same as reading language

#101

When I'm coding, I often listen to music, and when I listen to music, I often end up singing along. One thing I've noticed is that I can type out code at the same time I'm singing a song aloud. If I tried to do that while writing English, I'd start typing whatever I'm singing.

Ditto! I can also listen to a podcast or have a video playing in the background and still write code. Definitely can’t do that when trying to write English.

Re: To the brain, reading computer code is not the same as reading language

#102

When I'm coding, I often listen to music, and when I listen to music, I often end up singing along. One thing I've noticed is that I can type out code at the same time I'm singing a song aloud. If I tried to do that while writing English, I'd start typing whatever I'm singing.

Ditto! I can also listen to a podcast or have a video playing in the background and still write code. Definitely can’t do that when trying to write English.

Listening to music with lyrics is already hard for me when I'm writing code, but listening to a podcast is unthinkable--what kind of podcast? Don't you get distracted by the people talking?

Re: To the brain, reading computer code is not the same as reading language

#103
post #28

As someone who is fluently bilingual and speaks a third language and is also proficient or better in a half dozen programming languages along with having written code in many more, this is completely obvious to me. Learning a programming language is much closer to learning a complex board game than it is a natural language.

I feel exactly the same, I've been learning a second language and it's nothing like learning programming, in fact arguably the opposite, I've found that obsessing over grammar is almost detrimental to making progress with a new language. The confident students who aren't concerned with getting all the specifics of grammar exactly perfect are the ones that are making the most progress toward being conversational, they…

Makes total sense. If your grammar is wrong, the compiler will catch you.

If your English grammar is wrong, I will catch you.

Make progress.

Re: To the brain, reading computer code is not the same as reading language

#104

Earlier quoted context omitted.

I was originally surprised by the study and your comment, since I generally find no difference between natural languages , math and programming languages. (I am a math major). However, most of the people I interact with find my exposition methods curious in sense of structure. So, I shared this study with some of my friends, and they agreed with the study too. When I pointed out my surprise to them, they told me that…

I'm curious what's your first language. I'm learning Mandarin and find that it feels much closer to a computer language than English or Latin based. Though I don't think I'd say learning Mandarin (or any language) is anywhere near what it's been like learning computer languages. I find mathematical language different from both as well. They do feel like 3 different parts of my brain. Though math I'm highly visual (no…

My first language is Marathi which is an Indo-Aryan language. My other languages are

West Germanic: English

Indo-Aryan: Hindi, Bengali

Dravidian: Kannada

And currently, I'm learning German.

Re: To the brain, reading computer code is not the same as reading language

#105
post #59

Using the term “computer language” was an unforced error. Made perfect sense intuitively yet one could argue it’s a disservice since, as others have pointed out, it lights up completely different sections of the brain.

I have never liked the term “programming language”. Niklaus Wirth said somewhere that a better term is “programming notation”, and that has always stayed with me. That said, I like to understand a program (especially my own) by explaining it in English. There, I'm using generative, rather than recognition, processing. There might be some fruitful research in asking people to explain how programs work, rather than wha…

Very well put. And Wirth was right there with the correct insights once again.

Re: To the brain, reading computer code is not the same as reading language

#106
post #18
post #6

I wonder if editing a piece of written work would activate some of those same problem solving areas as reading computer code does. It that case you're more concerned about structure, grammar, correct wording and such. I find personally i'm in a different frame of mind that reminds me, at least, more of a coding frame of mind than a reading frame of mind. A lot of the time editing, I'm not really paying attention to t…

That sounds reasonable, I've helped edit a few things and need to decide on each pass whether I'm reading for content or structure. Totally different mindset. I've also found when I'm deep in a problem solving mode like coding I tend to be far less empathetic. So it seems to mess with my people skills too until I come up for air.

> I've also found when I'm deep in a problem solving mode like coding I tend to be far less empathetic.

My experience as well.

This is a side effect of a forced WFH. My kids are regularly at the receiving end of my outbursts when they interrupt me when I'm deep in work, more so when I'm debugging. In office on the other hand such 1-1 interruptions are rare.

Re: To the brain, reading computer code is not the same as reading language

#107
post #60

Earlier quoted context omitted.

> this is completely obvious to me This was my reaction as well: what, they needed to do a study to figure this out?

science isn't when you just decide that things are obvious and leave it at that lol. They probably have data and an experimental methodology and stuff now that future authors can build on to try to answer more complex questions.

[deleted]

Re: To the brain, reading computer code is not the same as reading language

#108
post #87

Earlier quoted context omitted.

Interesting. I feel like coding is not that dissimilar. In the early phases of learning a new coding language, I learn how to write lines of code. Sometimes it compiles, most of the time it would cause errors. At some point it works, but a more seasoned engineer could easily find places to refactor it in order to make it more extensible/flexible, easier to read, less brittle, and most importantly to this discussion o…

I don't understand this. If your code has wrong syntax it doesn't compile. If wrong grammar you can get very wrong results. But in english you can say "I go store" and it's understandable (which btw, can be a direct translation from several languages)

> If your code has wrong syntax it doesn't compile. If wrong grammar you can get very wrong results.

In both cases, when you get it that wrong that your meaning doesn’t come across correctly, it’ll usually get pointed out to you, either by the compiler or the person you’re talking to, so you can go back and try again.

Eventually, you’ve potentially gotten it right when the compiler stops throwing errors or the person you’re speaking to understands. Unfortunately, in both cases you may still not end up with the desired outcome as your compiler is “stupid” and cannot understand intent, only what you’ve written. Similarly, but different, the human you’re speaking to may bore of your broken language eventually and just move on.

There’s no perfect system for everyone, but it never hurts to remember the saying: perfect is the enemy of good enough. It doesn’t matter if your language skills are perfect, just that they’re good enough to convey your meaning effectively for the environment you’re in.

Re: To the brain, reading computer code is not the same as reading language

#109
post #14

This would explain why I can listen to music or TV while coding, but not while reading a book.

Somewhat opposite experience for me. I can’t listen to anything with words while coding. TV, podcasts, songs with lyrics all torpedo my ability to parse code. Instrumental music especially with a strong beat seems to help though.

I've noticed that I make more errors while listening to any kind of music. But, upon further reflection, it's probably because I tend to listen to music when I'm in the flow, writing large amounts of code.

Re: To the brain, reading computer code is not the same as reading language

#110
post #28

As someone who is fluently bilingual and speaks a third language and is also proficient or better in a half dozen programming languages along with having written code in many more, this is completely obvious to me. Learning a programming language is much closer to learning a complex board game than it is a natural language.

I like that example of "learning a board game." When I read text I "hear" conversations, and when I read code I "see" structures. Definitely different parts of the brain being activated.

This is also why visual low-code programming might actually succeed: it's closer to how you think about code than the actual code. It has the opportunity to visualize the structures you want to see, so you don't have to make that translation yourself.
Post reply on HN