After playing a little bit with QBasic when I was a kid, I was given a K&R C book. My takeaway: programming is not for me. I didn't look at programming seriously again until I was 23. This article is terrible advice.https://www.zeroequalsfalse.press/2017/11/29/c/
-
-
I don't think my post is at all rhetorical though. In my experience, devs who don't know any of the stricter languages, even if they create working products, tend to write code that no one else can understand. Programming requires discipline - the loose languages don't teach it.
-
My experience is that trying to bootstrap with a strict language causes people who could be great programmers to bounce off. I wrote Ruby and JS for years before writing way more code in Rust and TS and I have not experienced years of bad habits to unlearn.
-
On the other hand, as I said in my original post, sentiments about what it means to be a "real programmer" pushed me off of the path that eventually led me to working on the Rust programming language. So I just disagree with your empirical claim.
-
Isn't it possible you just didn't really have the interest or patience when you were younger though? People change. I've changed my opinions on lots of things over the years. Maybe you just weren't ready yet? ;-)
-
As an older programmer I plain don't know what "unlearnable bad habits" you're talking about. Did I understand you as saying that writing code in Ruby makes people resistant to code documentation earlier?
-
No, what I'm saying is you will initially learn to count on a person deducing, or a computer to determine at runtime, the state of your program, the pre/post conditions of a function, etc. - which is costly both in computer and human resources, and a habit you must then unlearn.
-
Whereas in go you are forced to understand the pre and post conditions of a function?
-
Type hints. A type hint is just an assertion about the the state of the program. Things are much simpler if you state your assumptions - "this parameter will be a number" helps both a person and a computer understand an important pre condition for a function dealing with numbers.
- 4 more replies
New conversation -
-
-
Heh, okay, how about for starters, documenting your argument types and return types? Most people learn about doc-blocks much, much later - it dawns on them much too late why others can't understand the functions they write, if they can't understand the before/after conditions.
-
I asked for an example of a bad habit in Ruby/JS but not Go that takes years to unlearn and you repeated the definition of types. I know the definition of types. I work on Rust and use TypeScript (strict) every day. I want an example of a bad habit that takes years to unlearn.
End of conversation
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.