Ask HN: Programming – what changed your mind about a language or feature?

18 points by open-source-ux ↗ HN
It could be anything, for example:

- a language you never thought you'd like but now you happily code in it. What won you over?

- a change of view regarding weakly typed languages vs strongly typed languages? Maybe you favoured one over the other but now your preference has changed (or opinion softened). What caused you to change your view?

- a different style of programming or problem solving after discovering a programming feature or pattern. How did that feature influence you?

14 comments

[ 3.0 ms ] story [ 37.6 ms ] thread
I didn't really like Ruby until I had to teach someone new to programming.

I explained what we were doing, then wrote it out in English, and besides the line breaks, he was so surprised that he had already written his first function.

It's hard to remember what a barrier to entry a few extra semi-colons can be for a brand new programmer.

Could totally relate to that . My introductory language was C and god I hated the language. I failed every programming test until I picked up python and felt like I could understand what programming is . Later I worked in school in C and loved it too. But python would be my first love.
I have been programming R for some work and enjoyed it but it wasn't very good code. So after digging a while to figure out how to get better with R I learned Racket.

1) "How to Design Programs" is the best book I have ever gone through for any language. http://www.htdp.org/

2) Went through "Realm of Racket" with my 11 year old daughter. http://www.realmofracket.com/

3) The documentation is the most consistent and well maintained. they created their own language 'pollen' just for this purpose. Best thing ever. https://docs.racket-lang.org/

4) I thought this was an academic playground and wasn't going to stick beside teaching me. Well, it is just awesome. I don't really touch Python much and my R code is light years better. I just went through a 1000 line program in R and It is now 40 lines.

Have been hobbyist programmer since 1978 and love Racket more than the other languages.

Interestingly enough it was my first real programming language. Imagine going from that to Java -- quite shocking.
Any details on how you managed to cut 1000 lines down to 40?
Yes I was able to make concise higher functions and iterate them. Before I went through learning Racket I was doing a lot of repeating things with slightly different changes. I figured out how to attack the problem in a repeatable concise way.
When I was new to C, I looked at the different code formatting styles, and I found the GNU style to be ugly and horrible on a visceral level.

Then I learned about the GNU project and Emacs and stuff, and I noticed the peculiar sense of my aesthetic sense being recalibrated, so that after a little while I found the GNU style code to be pleasing, symmetrical, and well thought out.

That was a really interesting experience because I learned how aesthetic snap judgments can be retrained, and quite quickly.

Modal editing was always the upsetting thing that I had to do when pico wasn't available on various servers. I don't remember what won me over, but it really doesn't take much to get a fairly large editing boost out of using VIM. A couple years in, I still barely use advanced features like macros and such but I still feel it's a big productivity boost.

I used a barebones atom install a few months ago for a livecoding presentation I did, and it drove me up the wall.

Java for me. I started using it at my most recent job and was a little horrified initially at what I was seeing in our codebase. The syntax does you no favors when in comes to code formatting. I also had reservations about the overhead of a strongly typed language as it was my first. BUT I ended up really enjoying the language and strong typing gives back so much more than it takes. Pleasantly surprised in the end.
I used to think that all languages should be garbage collected. I thought this because I thought it was the only way to make programs safe and I learned it was actually faster than manual memory mangement. I changed my mind when I learned that GC on average causes twice as much memory usage, and higher latency and Rust managed to achieve safety without it.

I used to think that exceptions were the best way to handle errors. What changed my mind was reading about the language Spec# that Microsoft made for the Singularity project. They actually REMOVED exceptions from C# and made many compelling reasons for why they did it. The one that I remembered most was that it was difficult to rely on a function's API, of only throwing certain kinds of exceptions, when it could change so easily. I also thought that boiler plate error handling code without exceptions was too much to handle. Go and Rust showed me that it doesn't have to be so bad.

I'm probably speaking for a lot of iOS developers here.

Objective-C is really odd looking, super verbose and bracket heavy that makes most programmers wince when they see it.

Not sure when or why my mind changed. Maybe it is a case of Stockholm syndrome as we had to use it (before the times of Swift). But now I very much enjoy the verboseness of the code, makes it easy to read and most things are super clear just by reading the code.

When I first had heard about Go (golang) I was severely unimpressed. Good support for multi-threaded programming was nice, but the rest of the language seemed like a step (or two) backwards.

Then I ran across this talk by Rob Pike:

https://talks.golang.org/2012/splash.article

What really impressed me about Go was the attention to detail on all the little things that are annoying in C and related languages. How they decided to re-order how variable declarations are done, things like that.

It was about paying attention to the "ergonomics" of programming that impressed me.

I took on a project in Java (web backend project) a few months ago, first Java experience, I was excited.

After a couple months, the gratuitous (or what felt like gratuitous to me at least) verbosity of the language and all sort of abstractions and intricate relationship of classes/interfaces in libraries (the typical Java programmer mindset) drove me insane. Icing on the cake was the atrocity of frameworks (had to work with a legacy Spring codebase) and the need for using an extremely complicated IDE with a billion options and knobs in order to write any sort of code.

I was incredibly happy when I finished and deeply regretted taking on that work. I didn't think it would have been that bad.

I think if Java was my only option, I'd probably switch to a different non-programming career.

To put things in perspective, I am a C (kernel development)/C++ (system programming)/Go (backend development) programmer usually, working with tmux+vim and respective plugins for lightweight code completion and navigation.

php, javascript, python, languages with ad hoc data structures and no compilation, no jars, no dlls, no .o[bj], no .h

People hate these because they like structure over speed and ease and what they perceive as high quality. Those people are going to die sometime in the next 0-50 years. So how much is your rigid, time consuming, kid safe, "right way" worth if you were going to die tomorrow?

I've found that people overwhelmingly like to do things in the most complex, restrictive way possible when they are being paid to do it and finishing means they might no longer be paid.