r/ProgrammerTIL • u/godfreddigod • Mar 02 '19
Other Do you prefer knowing a lot of programming languages or mastering in one?
43
Upvotes
r/ProgrammerTIL • u/godfreddigod • Mar 02 '19
10
u/heckruler Mar 03 '19
Well... Yes. You should do both of those. That said, Mastering one is more important than having a vague knowledge of a lot of different paradigms. Playing around with a bunch of similar languages doesn't get you all that much. Whee, Java, C#, C++. But they're all essentially doing the same thing. OO enterprise/application software. O-Camel, Malbolge, and SQL are all wildly different and broadens your horizons a little. If only to learn that "oh god, let's never do that again". If you master a language, you can get stuff done. And ultimately, that's what people care about. I like c. I do embedded work. C is a good language for that and knowing all the... frankly bullshit things it does helps me solve problems and I can quickly flesh out solutions. But you really should know how it's done elsewhere, if only to avoid turing tarpits. I would never try and format a webpage with C. I would never try and write a HW driver in javascript. Right tool for the right job. But.... the world of programming is simply too big to be a generalist. These days we've got:
The best language for getting stuff done is one you know. The best language for personal development is one you don't.
5
u/drunkferret Mar 02 '19
Knowing a lot. Far and away.
I'm really good in SAS because most of my career has been based around SAS. I don't use google to write it or anything.
...SAS sucks though. It's highly specialized.
I suppose if you 'master' something like C++ then maybe it would be different...but I'm going with knowing a lot. More tools in the toolbox.
34
u/spacemudd Mar 02 '19 edited Mar 02 '19
Being a master in one is great. Being experienced in a lot of programming languages is greater imo.
All programming languages hold the same abstract context. What changes is the syntax.
This is why it's very easy to pick up another language if you already know one.
Additionally, some languages are unforgiving to newbies such when it comes to threading or memory management. Having experienced those hurdles, it will make you aware of it when you use a forgiving language allowing you to produce more optimized code than the average user of the forgiving language.
24
u/cheraphy Mar 02 '19
Learn and get comfortable in a varied selection of languages from different paradigms and uses. For example: Python, C++, C#/Java, Javascript, Haskell, Rust. Maybe throw in a SQL dialect.
What you'll gain from that is the ability to think of a problem in many different ways. You'll also be able to pick up new languages easier with each one added. Plus having such a varied base will help you pick the right tool for the right job. You wouldn't write a micro kernel in python, and you wouldn't write a file managing script in Assembly.
Once you've done that, you'll likely find one or a few languages you really like to work in. Those are the ones you master. (marketable language skill notwithstanding)
tl;dr, be comfortable in a many different languages, but master (or at least become advanced) in one to a few
49
u/alex3305 Mar 02 '19 edited Feb 22 '24
I find joy in reading a good book.
5
u/Owndfrombehind Mar 02 '19
I think it’s better to focus on one language initially. If general design patterns, clean code principles or development workflows like TDD or DDD are known, it’s easy to apply them to other languages too.
IMHO its better to have more knowledge / experience in one language, instead of little knowledge / experience in multiple languages.
Like already mentioned in some other comments, it’s always good to have „more tools in the box“.
4
u/b4ux1t3 Mar 03 '19
You shouldn't learn programming languages, you should use programming languages to learn how to program.
You don't learn English so you can say "man, I know all about how English works!"
You learn English to accomplish tasks in that language. To write stories, or to get a job. The end result isn't knowledge of the language itself, it's what you make with the languages you know.
3
u/fuzzynyanko Mar 03 '19
I agree with the one saying focusing on one initially is a good idea. However, later on, general programming between languages hasn't been that hard at all
3
u/eterevsky Mar 03 '19
Knowing all the arcane details for your language is usually pretty useless, unless you are writing a very low-level code, like standard library. In most other cases you shouldn’t bother with metaclasses in Python or some advanced details of template programming in C++. That’s why knowing more languages is definitely more useful.
2
u/[deleted] Mar 03 '19
A lot of programming languages because trying to do everything with just one, will create unnecessary obstacles.
Are you going to provision your server with C++?
Write your frontend code in Haskell?
Write performant code in Python without knowledge in C/C++?
Sure, you can, but that doesn't mean you should.
2
u/[deleted] Mar 03 '19
When somebody ask a programming language question: which one do I learn, how many should you know... I always - not sure if correctly - assume the person hasn't been programming for very long.
There is no inehrent value in knowing many languages. You learn a language if you happen to need it.
eg. you know bash scripting if you set up a password manager server in your room 3 months ago because you felt like it
If somebody said "I've worked a lot with Python, C and Javascript" I think what his projects has he written, not that he's cool because he knows three languages.
2
u/rpgFANATIC Mar 03 '19
I prefer to have one strong language/library for backend, frontend, and scripting. Then, find as many excuses as possible to professionally use other languages to expand the list of techniques your chosen languages don't emphasize.
Having a breadth of languages helps the resume, but being really deep in a few things helps you carve out a spot as a trusted resource in the team
1
u/HeWhoWritesCode Mar 03 '19
you get two kind of programmers, those that have learned javascript, and those yet to learn javascript.
Fortunately you don't have to learn javascript to code, it just helps a lot to get your code in-front of a customer.
For mastery knowing python can be really helpful. But I can also see you surviving by just knowing c# or java.
Personally if you are going to work in a commercial setting mastering sql and my recommendation mastering pgsql will be timeless and a solid invest of your time.
1
u/Tarmen Mar 03 '19
For crud apps knowing your tools well is easily sufficient. If you want to write something more complex like a framework knowing different ways to approach a problem is generally a good idea(tm).
Most modern languages aren't single paradigm so you fairly naturally touch a bunch of styles like imperative, object oriented, declarative, static vs dynamic and functional. Knowing some more niche ones like logic, concatenative or first-class-macro languages can be quite instructive as well.
1
u/lambda-panda Mar 21 '19
Know a lot of languages and master a couple of them...
1
u/gabriel-et-al Mar 31 '19
I personally enjoy learning lots of languages, but the software industry values much more the expertise in one specific language (which is totally comprehensible).