Live data from Hacker News

Ask HN: What language do you think in?

news.ycombinator.com

61–68 of 68 posts

Re: Ask HN: What language do you think in?

#61
I want to have many different ways to think about problems, all linked up with ways to slide between them. (That's a big theme in SICP, the Feynman lectures, Doug Hofstadter, and Minsky's _Society of Mind_.) The languages that come up the most when I think programming thoughts: Haskell/ML (types, pattern matching), Scheme (procedural code, and my main larval-period language), E (OO: roles and responsibilities, message passing, contracts; event-loop concurrency & distribution; promises; capabilities), Python (actually coding most things), C (closer to the metal). Sketches on paper tend to use a Haskelly syntax with a Schemey meaning.

Re: Ask HN: What language do you think in?

#62

First I think visually about object classes and data structures, and how they relate to one another. Then I think in pseudo-code.

This is so funny, because ever since I was first introduced to OOP (about 19 years ago - C++), I've had visuals in my head for objects - not clear ones, but somewhere floating in there is the idea of some shape with sockets and protrusions, switches and dials, representing getters, setters, methods, etc. Again, it's always vague, but the concept always seems to be there. I can tell you, though, that they are an off-white color.

Re: Ask HN: What language do you think in?

#63
My pseudo-code looks a lot like a mix of Python and Ruby. One thing I like about Python is the forced indentation, which allows skipping any closing braces or "end"s. But Ruby tends to be closer to the way I think of OOP, and is closer to English.

I've also been known to write out in mostly English sentences as comments, then fill in the code that implements that explanation.

Re: Ask HN: What language do you think in?

#64
post #48

Am I the only one who doesn't think in any language at all? I just see little flashes and sort of feel ideas. I realize this is a very sucky explanation, but I've never heard it described. When I think about a program it is again a combination of images and feeling how a given algorithm I am designing will work. I only ever think about words when I sit down to write words, and then it is almost like I am transcribing…

In a programming or problem-solving context, this is sounds close to how I work in the very early phases of thinking about a problem.

When you are thinking out a problem is language (human or computer) any part of it?

If I understand how most people think (which I most likely don't), they have an internal monologue going, like they are thinking about going to the store and they think in their inner voice, "lets see, what do I need? Some eggs, milk, cheese". I never have any monologue internally, I either see a little picture flash by, or more often my thoughts have no relation to anything I could describe as sensory at all.

For example, I just thought of what I wanted to get to drink because I was really thirsty from gardening. No words were thought, but in quick sucession I percieved in my thoughts the flavor and temperature of tap water, and then the cold sweet syrupyness of coca cola, and I grabbed the coke. I can't describe it really, it's very much a 'now you are breathing manually' thing, once you think about how you think you are changing how you think.

Re: Ask HN: What language do you think in?

#65

Interesting. I'm surprised to hear people can effectively think about code in a language at all. Code is an abstraction of an essentially physical process (the computer doing things) so it seems rather odd to think about the problem at one level removed. I don't think in language generally unless I am intending to speak to someone. I tend to think in terms of motion through a physical space. Imagine yourself playing…

Aha, someone else. I would describe it as sortof pressure and stuff in there, like I'm feeling my way through a dark room and 'seeing' as I work the problem around in my head. All these people who say 'english' or something like that, how do you live? I would go insane after a day of that, it would be so slow and imprecise and completely misleading.

Here is another thing, tell me if this is true of you: I can't understand anything about how to solve a problem if I don't know completely 'understand' the context. In other words, I took several years of experimental physics at University, but it was totally bewildering to me. I understood the experiments perfectly (I mean, they aren't anything complex at that level), I understood the apparatus, I understood the mathematics and so on and on. At some point in every experiment, however, you had to decide whether your data supported or did not support the hypothesis. This is usually pretty obvious, but you were supposed to support it using chi-squared calculations and other statistical measurements of how well the data fits the hypothesis. I hadn't taken any statistics courses, so it seemed totally opaque and impossible to me to do this. I could never figure out what equation to use, or how to do it. I could follow step by step in the workbook and if I did so I would get a fine grade, but I was literally looking at the equations every 3 seconds as I worked the problem out. Anyway, I looked up the stuff in a statistics text, read the proofs and explanations of all the things I needed to understand, and suddenly it all made sense at once and I never had to refer back to anything. Once it 'clicks' everything is clear, like someone turned the light on in a dark room, before it 'clicks' I feel like I am suffocating.

Re: Ask HN: What language do you think in?

#66
post #48

Earlier quoted context omitted.

In a programming or problem-solving context, this is sounds close to how I work in the very early phases of thinking about a problem.

When you are thinking out a problem is language (human or computer) any part of it? If I understand how most people think (which I most likely don't), they have an internal monologue going, like they are thinking about going to the store and they think in their inner voice, "lets see, what do I need? Some eggs, milk, cheese". I never have any monologue internally, I either see a little picture flash by, or more often…

No, in the early stages there is no language attached to my thought processes, though as I mentally interact with the abstract concepts, I generally start to concretise into recursive functions. This conception of 'recursive functions' still has no notation attached to it, it's more that I start to decompose my solution (mentally) into cause and effect.

Re: Ask HN: What language do you think in?

#67

Interesting. I'm surprised to hear people can effectively think about code in a language at all. Code is an abstraction of an essentially physical process (the computer doing things) so it seems rather odd to think about the problem at one level removed. I don't think in language generally unless I am intending to speak to someone. I tend to think in terms of motion through a physical space. Imagine yourself playing…

Aha, someone else. I would describe it as sortof pressure and stuff in there, like I'm feeling my way through a dark room and 'seeing' as I work the problem around in my head. All these people who say 'english' or something like that, how do you live? I would go insane after a day of that, it would be so slow and imprecise and completely misleading. Here is another thing, tell me if this is true of you: I can't under…

I do feel something similar in that I can't really apply a bunch of rules to something. One of the disadvantages of not thinking in language is that I think it is very difficult to just apply a rule or formula to your thought process when you don't fundamentally understand what the formula is doing at a deeper level. If your models are not being stored in your head as language abstractions, you can't really apply a language abstracted formula to it. Another related problem is that I essentially have no memory for the things other people memorize with ease. I memorize concepts, motions and relationships but I cannot memorize 'labels' at all. I do not know my own phone number for example (2 years with my current one). So yes, I think trivial understanding is difficult with this model because you cannot just catalog a bunch of stock responses and rules for dealing with a certain topic, but deep understanding is far easier because you are not abstracting the underlying principals in a layer of obfuscation, the mental model is a simulation of the system rather than a description. I was useless in calculus until I started visualizing everything in terms of momentum and volume changing over time. Then it started to work. When it was memorize and record, I was useless. But once you have an actual model in your mind instead of a bunch of rules you can just derive the algorithms yourself (or at least get close enough to remember the right one)

Re: Ask HN: What language do you think in?

#68

Earlier quoted context omitted.

Aha, someone else. I would describe it as sortof pressure and stuff in there, like I'm feeling my way through a dark room and 'seeing' as I work the problem around in my head. All these people who say 'english' or something like that, how do you live? I would go insane after a day of that, it would be so slow and imprecise and completely misleading. Here is another thing, tell me if this is true of you: I can't under…

I do feel something similar in that I can't really apply a bunch of rules to something. One of the disadvantages of not thinking in language is that I think it is very difficult to just apply a rule or formula to your thought process when you don't fundamentally understand what the formula is doing at a deeper level. If your models are not being stored in your head as language abstractions, you can't really apply a l…

As far as I can tell we have the same thing going on in our heads.

Anecdote: In physics class (I was a physics major for awhile, so it was a 'real' physics class) there was what I guess was a very complex problem. The professor posed the problem and asked 'how do we solve this', and I raised my hand and told him the integral. It took me about 10 seconds or so f talking to say the entire equation. It blew everyone's mind, but it was really obvious if you could see it. I don't mean to brag, but if I was trying to think it through like socrates in a dialog I would have taken a week.

Post reply on HN