6 ms·
As I master my 15th or so language, I can't help noticing how often I have to search online for the simplest of tasks whenever I switch languages now because it
by kstenerud 5y ago
As I master my 15th or so language, I can't help noticing how often I have to search online for the simplest of tasks whenever I switch languages now because it's all turned into a big jumble.
Does it need parentheses or not?
How are closure variables managed? Do I need to release things?
Do lambdas require scoping braces or not? What's the damn syntax for them again???
Do I need to use case(X), switch(X), when(X), something else?
Do cases fall through or not?
How do I concatenate strings in this language again?
How do I get lengths in this language again?
Is it -> or => or functions? Are functions even first class? Can they be anonymous?
How did this language handle async operations again?
Anyone watching me work would probably think I don't know a damn thing. And after 25 years in the industry, I sometimes wonder the same thing.
- varjag 5y agoThat's because they are mostly the same language. Brain can't be fooled by manifestos.
- Viliam1234 5y agoI would probably print a cheat-sheet for each language, with simple examples covering the cases you mentioned here. Looking at a piece of paper next to monitor is faster than googling. > Anyone watching me work would probably think I don't know a damn thing. I guess looking at the cheat-sheet would only confirm their suspicions. :D
- sweaty 5y agoThis is how I feel too. And not just with programming languages, but with cloud platforms like AWS and GCP. I've spent the last 3 years working just with GCP, but I have prior AWS experience and recently started working in an AWS heavy role. I don't remember anything. I know what I want to do, and what the things AWS provide do, but I can't remember how, so I'm asking questions and looking things up online because I don't know and I feel like an idiot.
- cylon13 5y agoI agree with the spirit of your point, but I'd be hesitant to say you're "mastering" your 15th language if they are all jumbled together. It sounds like you've learned 15 languages, but mastery implies an extreme depth of understanding beyond the point of confusing minor details. I would bet you have at least one or two languages that you work in often that you never get this stuff confused for, and those are the ones you've mastered. The additional languages are subject to a sort of Jack-of-all-trades syndrome.
- kstenerud 5y agoYou'd think so, but that's not the case. I've mastered go so deeply that I even wrote [1] to subvert the runtime. But even with go I have to look things up after working in Kotlin for a week. [1] https://github.com/kstenerud/go-subvert https://github.com/kstenerud/go-subvert
- deleted 5y ago[deleted]
- varjag 5y agoSome people here learned, mastered and thoroughly forgot more languages and technologies than other people have started with yet.
- chakkepolja 5y ago> thoroughly forgot I am stealing this phrase
- nanomonkey 5y agoThis. I'm somewhat envious of my friends who stuck with one language like C, and are super proficient with the one or two languages that they know.
- exdsq 5y agoI ran between languages for a few years and have stuck with TypeScript for the last few months after deciding I wanted to be one of those people. Already so much more productive when I don’t have to Google everything I do.
- deleted 5y ago[deleted]
- marai2 5y agoI think that's just the nature of the ... problem domain. There are too many little details that are too similar and our brains have gotten used to Googling. Early on I started creating text files for all these little details for all the languages I know. And now a quick search for these details is an extension of how my brain works. In other words I realized I needed to deposit these chunks of information where I know I'll need to reference them in the future. Is it "else if", "elif", "elsif" in Python, Perl, Ruby - grep or quick search my ruby.txt, ocaml.txt, etc. file. And since I live in emacs, this takes just a few characters to accomplish. Kinda similar to https://learnxinyminutes.com/ https://learnxinyminutes.com/
- chakkepolja 5y agoNice. I should assemble some shell scripts or python to do this now.
- wiremine 5y agoI've mastered about a dozen and can read another dozen or so. I have the same problem you're describing, but it tends to be with languages I haven't used in a while. I've also resigned myself to be ok with googling a lot of things: "list comprehension python" "typescript generic constraint" "golang package visibility" Once I got ok with this approach, I became a much happier and productive developer. Rather than beating myself up that I couldn't remember the details, I just "outsourced" said details to Google/StackOverflow and focused on the big picture. As long as I grok the semantics, I haven't missed remembering all the syntax and idioms of each and every language.
- tyingq 5y agoAlso tricky because many things "work" but aren't stylistically acceptable. Like, python oo is perfectly happy with "this" instead of "self".
- choeger 5y agoI don't agree that you look like you don't know a damn thing. You know quite a lot. In fact, I would happily hire any programmer for, say, a python or a C++ job, that knows nothing about the language in use but knows to ask precisely these questions. Bonus points for questions about function semantics and memory management. Everything else boils down to syntax and ecosystem/tooling. The former is essentially irrelevant and the latter changes so often and is used differently in different contexts that there is little point in asking about prior experience.
- philipswood 5y agoIt's nice, when doing actual work on a language you have zero experience with, to have a clear intuition about what to expect and what to search for and to feel confident that you'll be able to get things done based on having done it with so many other languages before. If it's not too unusual, it feels similar to other tools you've picked up before. If it isn't it's interesting. Something like: "Oh, OK, Swift has a switch right? Yeah. Does it require me to explicitly break? Yeah. Can I give ranges or patterns? That's cool, they use named parameters in Smalltalk style, probably comes from Objective C, right? Nil! charming, like Golang or Pascal. What do you call these ?. and !. 's? Reminds me a bit of ?. in JavaScript. It's nifty: you can enforce a value not being nil or specify a default.. Hmm, these guards are interesting, how do they work... Etc " So obviously you need to get someone to check for footguns in your code, but after enough playing with toys you tend to get to a place you can write solid code in a new language very quickly, and where getting to a solid level of competence is relatively quick.
- fouric 5y agoHypothesis: this is your brain doing normal garbage-collection on pieces of information that you haven't accessed frecently (frequently + recently) - you're at the tail end of the forgetting curve[1]. Does your experience confirm or deny this? That is, do you have much more trouble with languages you learned 5/10/25 years ago than ones you were using last month? Or is the process random, and you'll forget features of a language that you were just using? Alternate hypothesis: you're getting old, and your memory is starting to go - nothing to do with programming languages in particular, the process is just more noticeable there because we have to remember so darn many little things. Less depressing hypothesis: your brain has gotten out of the habit of remembering those things. I used to be extremely bad at remembering names, until I started paying attention to them because I learned that people really like it when you remember your name. Now I'm great with names without even trying, and I'm convinced that you can also train yourself to be better at remembering other things (i.e. programming stuff) than your natural tendencies. [1] https://en.wikipedia.org/wiki/Forgetting_curve https://en.wikipedia.org/wiki/Forgetting_curve
- Silhouette 5y agoAnyone watching me work would probably think I don't know a damn thing. And after 25 years in the industry, I sometimes wonder the same thing. I suspect the people watching who thought you didn't know a thing would probably be the ones too inexperienced to recognise what you describe. I also suspect that every other programmer with 25 years of experience who can be productive using many different programming languages would immediately recognise and empathise with the feeling you describe, and they also have a search window permanently open while working.
- lastofus 5y agoMy brain is in the exact same state, which is frustrating when doing live coding interviews, as suddenly it's impossible to not come off looking like a complete beginner. Throw it some nervous jitters on top and it gets ugly fast.
- worrycue 5y agoI know people hate language wars and always reply with “Use the best language for the job.” but wouldn’t it be great if there was a language that could do it all optimally (or at least adequately). Then we can focus on just one language to master and don’t have to keep in our heads a jumble of languages.
- hpoe 5y agoWe already have that language but people keeping getting whiny about parentheses, and refuse to use it.
- Nadya 5y agoBasically any modern, turing-complete, and non-esoteric (eg. Brainfuck) language fulfills the "at least adequately" part. So it comes down largely to preference and style of the language itself. I can't stand C# code or that the language uses Allman style over K&R because I truly find Allman style more difficult to read. I shouldn't - the difference is very minor - and although I work with a C# codebase in my day-to-day work I always struggle parsing the code quickly compared to languages where K&R style won out. Now "optimally" is an entire can of worms because there are some aspects where you need to make mutually exclusive choices. You can optimize A or B but not A and B for multiple sets of A and B. So you'll end up with multiple languages or multiple flavors of a single language where decisions were made to optimize for varying sets of A and B. A and B can even be simple things like "How easy is it to footgun yourself?". Should you make code that is more boilerplate/difficult to write in order to prevent people from footgunning themselves or do you expect your developers to be more experienced and allow them to write more succinct code but having to be aware of and avoid potential footguns themselves? There are a lot of domain-specific languages for precisely the kinds of trade-offs are made that certain fields want/need. For example, mathematics domain languages tend to be 1-indexed instead of 0-indexed. By the way that language is LISP. [0] Just in case anyone is unfamiliar with Allman/K&R styles mentioned you can see examples on Wikipedia: https://en.wikipedia.org/wiki/Indentation_style https://en.wikipedia.org/wiki/Indentation_style
- jerf 5y agoI've dealt with 5 different databases this week. Is it SHOW CREATE TABLE blah, DESC TABLE blah, DESC blah, sp_help blah, \d blah? Is this the database that supports CROSS JOIN? What exactly can I do with aggregate functions and a GROUP BY in this database again?
- jamesfinlayson 5y agoUgh, this a thousand times! It's all SQL but all these little side things like describing a table or listing all tables are completely different across the board.
- lborsato 5y agoFor me it’s trying to remember the ‘for each’ syntax in every language. I normally bounce between 4 or 5 languages every day.
- Traubenfuchs 5y agoIf you don‘t remember those things, you haven‘t mastered the language. Mastering a language means not having to look up language features all 5 minutes. -> you haven‘t mastered 15 languages.
- twox2 5y agoI kind of think this makes programming all about the IDE.
- Fire-Dragon-DoL 5y agoFor what is worth, it's the same problem with normal language. I know Italian and English, "great, I can talk to two kinds of people", except that my Italian is fully distorted by my English now (I talk both languages constantly, but I do live in an English speaking country now). Anyway knowing many languages has some downsides, but in the end if you write the same one for a couple of months the problem of searching disappear. When you switch another couple of months and it's gone again.