Live data from Hacker News

The language brain matters more for programming than the math brain? (2020)

massivesci.com

271–280 of 465 posts

Re: The language brain matters more for programming than the math brain? (2020)

#271

It think this is silly on multiple accounts. I'll claim that there's not real thing such as a "language brain" or "math brain." I'll also claim that most people don't know what math is, and that their evidence supports a "math brain". Math isn't about calculations/computations, it is about patterns. You get to algebra and think "what are these letters doing in my math" but once you get further you think "what are the…

If we taught music the way we teach math. No wonder so many people are "bad at math". “Music class is where we take out our staff paper, our teacher puts some notes on the board, and we copy them or transpose them into a different key. We have to make sure to get the clefs and key signatures right, and our teacher is very picky about making sure we fill in our quarter-notes completely. One time we had a chromatic sca…

Of course Brett Victor has the essay on his website: https://worrydream.com/refs/Lockhart_2002_-_A_Mathematician'...

It is a great read!

Re: The language brain matters more for programming than the math brain? (2020)

#272

Earlier quoted context omitted.

> Coding IS math. Programming is an expression of logic, which is absolutely mathematics. But then we also have to think about naming variables and classes, structuring our code so that it is more readable by other developers, and so on. That's less about formal reasoning and more about communication. There is an engineering aspect to programming (prototyping, architecture, optimization, etc). It's a combination of m…

>Programming is an expression of logic, which is absolutely mathematics. and also philosophy.

As in GNU vs. Microsoft? Or something more foundational in logic?

Re: The language brain matters more for programming than the math brain? (2020)

#273
post #239

Earlier quoted context omitted.

Do you think mathematicians don’t have to think about naming variables and structuring proofs?

The presumably-mathematicians who wrote my Algorithms textbook (CLRS) didn't seem to think giving the variables in their algorithms useful names. They just use i, x, etc. all over the place and don't even consider giving things actual names. This makes the book much less accessible than it would be if they treated it more like most people write code.

That's how it is in applied mathematics. That's a hardcore computer science textbook. If your job is computer science research, inventing new algorithms, that is the kind of book you will get used to. There are better options for practical learning.

Re: The language brain matters more for programming than the math brain? (2020)

#274

Earlier quoted context omitted.

>Programming is an expression of logic, which is absolutely mathematics. and also philosophy.

As in GNU vs. Microsoft? Or something more foundational in logic?

Classes are a platonic ideal representation of reality?

Re: The language brain matters more for programming than the math brain? (2020)

#275

Good code doesn’t just solve a problem, it solves it in a way that’s readable and modular. I think the problem-solving part of coding requires math skills, while the organization part requires writing skills. The organization part affects the problem-solving part, because if you write messy code (that you can’t reread once you forget or extend without rewriting) you’ll quickly get overwhelmed. Writing large math proo…

Regarding mathematical > concepts that are intrinsically complicated, I'm not a mathematician, but I figure mathematicians aim for clean, composable abstractions the same way programmers do. Something complicated, not just complex in its interactions with other things, seems more useful as a bespoke tool (e.g. in a proof) than as a general purpose object? > Whereas programming has more “small steps”: even someone who…

> You cannot possibly write or deliver spaghetti, working or otherwise, if you're not capable of remembering what you wrote three minutes ago.

Forth programmers make a similar point. Forth is stack based; you typically use stack operations rather than local variables. This is ok when your 'words' (analogous to functions/procedures) have short and simple definitions, but code can quickly become unreadable if they don't. In this way, the language strongly nudges the programmer toward developing composable words with simple definitions.

(Of course, Forth sees little use today, and it hasn't won over the masses with its approach, but the broader point stands.)

Re: The language brain matters more for programming than the math brain? (2020)

#276
That makes sense.

Probably the most valuable math classes for me, were ones that had me use algebra to solve word problems.

And, fundamentally, all languages describe the same stuff, using different tokens. That is pretty much in line with programming languages.

Re: The language brain matters more for programming than the math brain? (2020)

#277

Earlier quoted context omitted.

> Most coding doesn't need much of any math past boolean logic and very basic set operations Coding IS math. Not "coding uses math", I mean it is math. Mathematicians do not deal in objects, but in relations among objects; they are free to replace some object by others so long as the relations remain unchanged. Content to them is irrelevant; they are interested in form only. - Poincare[0] I don't know how you code, b…

>Coding IS math. No, not always. Quite a lot of high-level code doesn't require any math at all. It doesn't take math to perform CRUD operations, which account for a lot of programming work. Sure, the underlying machine code is all based on math, but the higher level programming doesn't need to involve a single math equation for it to be useful. Let's see where the goalposts move now...

All of that code is a series of logical statements and expressions. Mathematical logic.

But the CRUD logic is so basic and boring, so obvious, that it doesn't require any thought.

Re: The language brain matters more for programming than the math brain? (2020)

#278
Not sure why the title left out the essential term: it matters more for learning programming

I believe the goal is to encourage those (young people) allergic to math but good in languages to realize they could be good at programming. That's worthy and important (though ironic to use a scientific study to do so).

As for the larger question commenters are raising, I notice often programmers reducing programming to problem-solving, and that to modeling, thence to math writ large; then they prove their point by noting that the most significant algorithms have strong and deep roots in math. The argument is: if the pinnacle of programming is math, then the more math-like programming is (in people and style), the better. (Hence: functional programming and provable algorithms are the epitome)

This argument is invariably made only by math experts, and does have the effect of reducing competition and selecting for like-minded persons, so there's at least the possibility of infection with self-interest and bias to the familiar.

I think the real distinction lies in this: with math, once you have a model, you fit things into that, and exclude other things. You do perfectly, but only in your domain. With language, any differance (any difference that makes a difference) starts to be named and tracked and dealt with somehow. It may grow in confusing ways, but it turns out (like architecture) it actually makes much more sense to adapt the structure to the use and relevance than vice-versa.

Sure, some subset of architecture is engineering by necessity, and it's probably even the hardest subset. But that's also the most portable knowledge and practice, and I would argue, thus easier to find and deploy once you've isolated such a need, particularly since mathy stuff fits nicely in a reusable library.

So math is an important but relatively isolated part of programming, and thinking it's ideal for everything is missing the point that programming matters for some purpose.

"attention is all you need" is but one example of the priority of relevance over structure in systems.

Re: The language brain matters more for programming than the math brain? (2020)

#279

Earlier quoted context omitted.

I don't think that quote really supports coding and math being equivalent. To me, the quote provides an abstraction of math through a structuralist perspective. Language can also be viewed through this abstraction. I think coding could share the abstraction, but that doesn't make the three of these fields equivalent.

> coding and math being equivalent Please see lambda calculus. I mean equivalent in the way mathematicians do: that we can uniquely map everything from one set to another

> Not "coding uses math", I mean it is math

> I mean equivalent in the way mathematicians do

That sounds like you're backing off from your original claim, probably because it is impossible to defend.

That you can use mathematics to describe code doesn't seem very different from using math to describe gravity, or the projected winner in an election, or how sound waves propagate.

Isn't the primary purpose of math to describe the world around us?

Then it shouldn't be surprising that it can also be used to describe programming.

In the real world, however, software engineering has nothing to do with mathematical abstractions 99% of the time

Re: The language brain matters more for programming than the math brain? (2020)

#280
post #78

There is no such thing as a "language brain" or a "math brain" unless you show experimentally that those bunch of neurons can be grouped into two non-overlapping regions dedicated to "language" and "mathematics". Mathematics itself is a human-made formal language that can be bootstrapped from definitions and axioms of logics and set theory, which have to be given in human language first. Experienced mathematicians re…

What about Wernicke's area and Broca's area? If damaged they produce causal changes to our use and processing of language. I agree it's not as simple "language brain" but there are physical structures in the brain that are directly related to language.
Post reply on HN