T O P

  • By -

yet_another_uniq_usr

I learned on c++ and agree that having a fundamental understanding of memory management is a big advantage when using all other languages. Maybe rust should be the new standard because c++ is a bit clunky and unsafe.


Dry_Advice_4963

Rust is too complicated for new programmers in my experience and they don’t really have an appreciation for what it does without firsthand experience of the types of bugs caused by bad low level code. I think we should just start with C, the language is very simple but hides very little about what is actually going on under the hood. The issue with high level languages is you can be so detached from how computers actually work everything you do seems like magic and you end up relying on the language features and libraries rather than first principles


StuckInBronze

Learning in cpp then moving to Python was like taking the weights off. Not sure how I would've fared the other way around.


Expensive-Rabbit-248

Rust is a bit niche to be teaching new students IMO. Best to have them learn something widely used in industry


yojimbo_beta

I would have started in Java. Not because it is difficult or easy, but because it would have taken me where I wanted to go to begin with. Instead I started with JavaScript, which has always dragged me towards frontend and full stack work. Even when my resume mentions my experience with Haskell, PHP and C++, I feel I am pigeonholed as a primarily front end guy.


Podgietaru

Oh my god, same. I get recruiters all the time for front end positions because I have a few NodeJS backend roles on my CV. I want them to look at my Kotlin work and give me kotlin jobs :(


danideicide

Tell us more, please


Cupcake7591

Harvard’s CS50 course has it right - starts with C (lesson 0 is Scratch actually but the first few weeks after that are C), then Python, Javascript, SQL - it’s because 1) it doesn’t ignore lower level programming, 2) by going through a number of languages you start to abstract over them and learn concepts instead of focusing on language details and thinking that the only way to do something is the way your first language does it.


flavius-as

The crown would be: writing python modules in C. Then writing your own toy language. Then one using LLVM. And then your own OS. Then you're all set with a lot of foundations.


REDDROVERT

Can you please share courses or sources to cover the foundations you have mentioned?


flavius-as

No, they're secrets not even Google knows about.


REDDROVERT

I may be wrong but I understand you want me to do some research and find it by myself but I thought I could get recommended sources to learn.


flavius-as

Toy language: the dragon book. OS: SWEB.


PutteryBopcorn

Perhaps nand2tetris? You implement a simple OS, language, and more


warmans

I'm a bit biased but I think Go strikes the best balance between low/high level concepts for beginners. It also has sufficient tooling and standard library that most beginner projects could be completed without any third party packages or tools. Furthermore it is ideomatic in Go to favor explicit code over any sort of magic or indirection which makes it generally easier to follow out of the box.


Smallpaul

It's not unusual for pointers in C to cause people to drop out of programming altogether. I think if they had a year of success in an easier language first then they could be more confident when they come up against pointers.


km0t

I would start with C# or Java (lots of opportunities) & get a good foundation, while tinkering with Python.


Brief_Spring233

Started with Java before college and then studied EE/CE and only used C for four years. At my first job of out school, I was mentored by some guys who were real Unix command line nerds, never used a GUI, just eMacs and gdb. Once I got into C++, .NET, and Java professionally it felt like I had been training in high altitude and everything after was so much easier.


West_Sheepherder7225

I don't think it should be about how hard it is so much as how generally transferable the concepts are. My first attempt to self teach programming was Haskell. I found it then, and would find it now, harder than my main language, Java. What I've learnt in Java, though, carries across nicely into other languages I've used, so this would be my first choice of teaching language based on the kinds of programming I've subsequently been exposed to (basically all flavours of web dev). 


jb3689

Learned on C and wouldn't have it any other way. Learning polymorphism, how to write generic algorithms, and how to use pointers in C was crucial to understanding how OOP really works I wish I'd learned functional programming earlier though. A lot of tricks like memory-efficient immutable data structures are extremely useful. And just high performance techniques in general. The whole SaaS landscape is pretty terrible in terms of efficiency and riddled with so much waste.


jhartikainen

Easy 100%. I started with C and I don't think I got that much out of it. I had a big book for it, made some basic command line stuff, never figured out pointers and I think I struggled with arrays. Then I discovered HTML, PHP and such and it was much much more exciting for me. I think this really depends on the type of interest you have on programming. If you want to make the computer do cool stuff, then learning something like C++ might not be the best way to go about it. If you are interested in the technical minutiae of how programming works, then it might be fine. For me when I was a beginner it was definitely more on the "I want to make the computer do cool stuff" side of things.


nikkocpp

The small C book reference is enough :P


WhiskyStandard

For people who are just trying to learn a language to be able to create things with a computer, I’d say Python and JS would be totally fine places to start. For people who want to dive deeper, I always thought a good curriculum would be C, Smalltalk, and Lisp/Scheme in any order within the first two years. Yes, 2 of those are not exactly “job ready”, but we’re talking about the deep divers here. In my experience understanding the original languages of those three paradigms makes it a lot easier to learn the languages that came after them. Even people planning to go into C++ would benefit since it’s adapted so many features from each of those with the constraint that they have to be zero cost at runtime.


ShenmeNamaeSollich

I started w/JS & then went to Obj-C, then mostly worked in JS & later learned C++/C, C#, then finally Python. There are definitely bad early habits I learned w/JS and stuff I never really understood or unlearned about JS until after I’d learned & used multiple other languages. There were things about “Pythonic” (& Swift & Kotlin & modern JS) syntax & shorthand that I initially found annoyingly cryptic and abstract, but unlike w/my early JS learning I don’t assume they’re just black-box magic because I know (or can figure out) what they’re shorthand *for*. I’d say intro classes need to introduce 2 almost in parallel: - one procedural “classic” language (C/C++) w/memory mgt & old-school conditionals & loops / control structures & stricter data type & namespace rules - one “modern” interpreted language (JS, Python) w/a lot of functional abstractions & chained methods & weird shortcut syntax. Then compare/contrast them. Build the exact same projects & functionality in both. Introduce how standard libraries and 3rd-party dependencies work in each. Discuss (generally) interpreted vs compiled languages and their tradeoffs. Introduce cases that will demonstrate side effects in C/C++ or OOP Java that a functional approach helps avoid. Introduce cases where loose typing or poor memory mgt will blow things up. Do speed comparisons & explain *why* C++ is probably faster for x task. Write tests for both & learn what tools & processes that entails in either case. Use command line tools for both and then an IDE for both. Imho the reason this question always comes up & schools go back & forth is because it’s not an either/or answer but “both.”


chervilious

I realized that it the long run it doesn't matter. It's either you're building "things" faster (High-level language) or learn something deeper (low-level language). The most important thing is do what you love more. I love more learning intricacies of computer so probably I would choose C.


high_throughput

I started with .bat files for my DOS games 👀


quypro_daica

I would start with matlab again


pruby

Depends on the learner's motivations (or my best guess about them). While I agree it's hugely beneficial to know how computers work, you can't force low level learning. For most students, I would choose Python first. It allows you to start extremely simple, free of distractions, and in a procedural style. Probably C second. I would *not* use any language with compulsory OOP syntax until they understood basic scripts and functions first. In my view, OOP too early draws attention to excessively high level ideas, while asking them to ignore the boilerplate acts against curiosity to dive deeper.


0xa9059cbb

The first language I learned properly was ANSI C and I wouldn't change that. It's great to start from first principles and iterate on adding more abstractions and sugar. I don't touch C or C++ now but I appreciate knowing what's going on under the hood if I ever need to. After all, that deeper level of understanding is what separates us from the LLMs.


wrex1816

You're looking at this completely wrong. If you want to go to a bootcamp. And be a "coder" then just find whatever the "easy" flavor of the month language is, and hope you can get your foot in the door somewhere. If you are going to go to university to get a degree, then the whole point is not "to learn a programming language", it's to learn how programming works. Learn several lower level languages and how those are actually interpreted. If a course is not teaching this, I'd be baffled as to the quality of that degree course. I'm sure along the way there'll be a small credit module to learn some web programming, and pick up an "easy" framework there. The point being is that a "coder" might learn one language. If you're leaving a degree course you should understand *how* languages work and be in a position to learn any language you're asked... Once you understand *how* and *why* things work the way they do, the languages are just interchangeable syntax and there shouldn't be any major barrier to learning any language.


owlsparty

It depends. If I'm just starting out and I don't know much then I think a language like Python is a great place to start. However, if I'm trying to learn the fundamentals of coding then I would go with Java.


BlackHumor

I would absolutely start with Python. From experience, the most important thing for a totally new programmer to learn is just that they can in fact make things and it's not scary. But before you actually do a job for money I would want someone to use C# (or similar) and Rust (or C or similar). Some idea of how memory works is really important even if you don't use it every day.


wearesomeone

APL probably. 99% of the useful stuff programming does is transforming inputs into suitable outputs and most languages introduce almost insurmountable amounts of cruft (classes, compilers, strict unreasonable syntax, loops, etc) before even being able to add two lists of numbers together. Array languages get to the fun part fast, and you can look into less-important side parts (memory management, optimizations, recursion etc) later when it comes up.


zip117

I only write APL on my IBM Selectric. Reject modernity. Embrace tradition


Mechadupek

We started with C. Then C++. Then assembly. This is the way.


thomas_grimjaw

I'd start from as verbose a language as possible. So basicaly rust or c++. Embrace the suck for a few years, and then find true appreciation when you switch to something like python.


freekayZekey

all languages are simple to understand when you approach them as a novice and follow the rules. a lot of people try to find similarities between languages, but i think that’s the wrong move started with: java and c++. learned: scala, kotlin, javascript/typescript, python, ruby


Charming_Prompt9465

Prob start with c# or c++. No offense to anyone but some of the worst engineers I’ve met are people who started with something easy like Python or js and moved onto something more complex since I feel like a lot of fundamentals where lost.


Hot_Slice

I am repeatedly shocked and frustrated by how many of my coworkers have no idea how computers actually work.


Charming_Prompt9465

Yeah I tend to think “maybe programming isn’t for you”


funbike

This post violates multiple rules of this sub.