3 ms·
This line from the abstract is the key takeaway for me: > The interviews revealed that programmers make failed attempts to relate a new programming language wi
by lidHanteyk 6y ago
This line from the abstract is the key takeaway for me:
> The interviews revealed that programmers make failed attempts to relate a new programming language with what they already know.
This is the map-territory problem. Folks think that they know the territory (computation) because they know a map (one particular language). I find it telling that some programmers explicitly used cheat sheets to literally map their understanding from one map of the territory to another.
Folks are too quick to think that something is alien just because they do not understand it. A moment's reflection will assure us that every programming language ever used by people has also been invented by people. The feeling of alienation that folks have upon encountering a new language is entirely only a feeling, although understandably perhaps fear of the unknown is the most fundamental fear [0].
I personally know about a half-dozen languages for my daily work, and I suspect that that is also the case for most other programmers; I am not the sort of person that learns new languages for no reason. But the paper only shows small slices of each investigated programmer's thought processes, because it only shows one or two old languages for each new language being learned. I wonder to what degree there are common languages that are used perhaps as linguafranca (e.g. that two-thirds of us know JS and two-fifths know Python [1]) or for the ambient semantics of computation (e.g. that most programs are written with C's behavior in mind).
[0] https://www.sciencedirect.com/science/article/pii/S0887618516300469?via%3Dihub https://www.sciencedirect.com/science/article/pii/S088761851...
[1] https://insights.stackoverflow.com/survey/2019#technology https://insights.stackoverflow.com/survey/2019#technology
- thaumasiotes 6y ago> A moment's reflection will assure us that every programming language ever used by people has also been invented by people. Not at all. We produce chemicals by splicing the code to produce them into bacteria, culturing the bacteria, and harvesting the chemical. This is obviously an application of programming, and just as obviously uses a language not invented by people. We use it anyway, mostly by application of copy-and-paste.
- lidHanteyk 6y agoOkay, so the contention is that humans did not invent the design of DNA, and thus we did not invent programming with DNA. However, we invented animal husbandry several millennia before finding the structure of DNA, and we invented the concept of genetics to discuss and manipulate traits a century before we isolated DNA's low-level structure. Even today, knowing how DNA works, we usually program at the level of genes; see e.g. [0] where a Youtuber is doing genetic manipulation and programming. This is the same sort of map-territory situation [1] as in my original post. The RNA World [2] is the territory, and genetics is our map. [0] https://www.youtube.com/user/TheChemlife/videos https://www.youtube.com/user/TheChemlife/videos [1] https://en.wikipedia.org/wiki/Map%E2%80%93territory_relation https://en.wikipedia.org/wiki/Map%E2%80%93territory_relation [2] https://en.wikipedia.org/wiki/RNA_world https://en.wikipedia.org/wiki/RNA_world
- chubot 6y agoThe interviews revealed that programmers make failed attempts to relate a new programming language with what they already know. I've seen this a lot in shell code while working on Oil [1]. For example, ${array} means ${array[0]} in bash and ksh-derived shells. That is, if you don't put an index on array, it evaluates to the first element in an array. This is a weird semantic that basically no other language has. And it's been true for decades, and is documented. But people still report bugs about it on the bash mailing list (I saw on a few days ago). I got rid of this behavior in Oil for exactly that reason, along with fixing tons of other warts, while remaining compatible. You can opt back in with 'shopt --set compat_array'. Another issue is using (a; b) to mean grouping when { a; b; } is technically more correct. () starts a subshell in addition to doing grouping. You wouldn't really know unless you mutate a variable in the group -- it will show up in one case but not the other. The wart where ; is required before } and not ) doesn't help. --- So shell is full of surprises, and Oil is meant to be more comfortable for programmers coming from say Python, JS, or Ruby. People bring those expectations to shell, and they get frustrated with it. [1] http://www.oilshell.org/blog/2020/01/simplest-explanation.html http://www.oilshell.org/blog/2020/01/simplest-explanation.ht...
- zimpenfish 6y ago> The wart where ; is required before } and not ) doesn't help. Also the spaces are required between the {} and commands in Bash which is another brainclunk to deal with.