News for hackers. Stuff that matters.
Re:To become a good C programmer (2011) by ams6110 on Sunday May 01, 2016 @02:11PM (#11607196)
I would say generally I feel that way about any language I've learned. Initially they are pretty easy and the examples given include slick solutions to contrived problems. Then you get into wanting to do real work and you learn about all the corner cases and ambiguities and landmines that are hidden farther afield.

Can anyone name a language that they've grown to like more the more they learned about it? I would guess maybe only those in the LISP family would make the cut.

Re:To become a good C programmer (2011) by ArkyBeagle on Sunday May 01, 2016 @02:28PM (#11607277)
My favorite language remains 'C'. You don't have to even look at the corner cases, landmines and ambiguities - use the subset of the language that works.

Other than things like signed integer weirdness, most complaints about 'C' revolve around the library. Well, don't use those parts of the library.

Re:To become a good C programmer (2011) by optforfon on Tuesday May 03, 2016 @09:27AM (#11620396)
Except that generally the point of using C is to squeeze performance out of your alogorithms - so you can't limit yourself. But even the simple straightforward stuff has been done just sloppily. I think we just take for granted that it's part of the learning curve and that programming just isn't easy.

And eventually your fingers memorize all the nuanced and sure if you don't screw up it all works. But it's designed in a way where you end up shooting yourself in the foot. It's hard to reason about pointer and reference notations, everyone eventually miss a break in a switch - const is weird, arrays vs. pointers is weird. Symbols are needlessly overloaded to do different hings. Things that seems like they'd work for strange reasons don't EXAMPLE:

foo(const char p) { }

main(int argc, char argv) { foo(argv); }

I really really recommend opening up "Expert C Programming". I promise by page 50 you will be angry - not because there are so many gotchas, but because most of them are completely fixable. Just no one has bothered to do it

Re:To become a good C programmer (2011) by MichaelBurge on Sunday May 01, 2016 @02:30PM (#11607286)
Haskell can be annoying to work with in the beginning, since the slick quicksort examples don't really explain why you'd want to use it to write something real. But then your project grows bigger, and the type system maintains sanity in a way you don't otherwise see. Other languages usually use tons of unit tests everywhere to enable refactoring, but then they bog you down if you really need to change something.

I guess it has problems with records, space leaks, and deployment to old machines. Maybe ML or F# are just as good for this purpose; I haven't really used them.

Re:To become a good C programmer (2011) by jsmith0295 on Sunday May 01, 2016 @05:18PM (#11607895)
Objective-C, actually. I had really only used Java and a little C++ and PHP before I learned it to start doing iOS development (still iPhone OS at the time), and while I initially hated the syntax and found it confusing, I really ended up appreciating a lot about how things were done in the language. Although that was mostly things which originated in Smalltalk.
Re:To become a good C programmer (2011) by groovy2shoes on Monday May 02, 2016 @01:43PM (#11613656)
> Can anyone name a language that they've grown to like more the more they learned about it? I would guess maybe only those in the LISP family would make the cut.

You're correct that a few of the Lisps have had this effect for me (Scheme, Common Lisp, EuLisp, Le-Lisp, elisp), but there have been a few dialects that I came to like less and less as I learned them (note that I do not necessarily dislike them, rather I'm disappointed by them): Clojure, Newlisp, and Racket, for example.

There are a few non-Lisps that I find myself liking more and more as I use them: Kitten and Mantra. They're both concatenative languages that take somewhat different approaches from the usual Forth-likes. I'm still not super proficient with them, though, so it's possible that the derivative of my fondness for them will invert yet. I've also had that experience with ksh (believe it or not) and Vim (a DSL for editing, if you will).

There have also been a few languages that have had a sort of "roller coaster" effect: at first they excited me greatly, then as I learned them better and better, I liked them more, then less, then more…. Some examples that come to mind are C#, Datalog, Haskell, Modula-3, OCaml, Prolog, Rust, and Standard ML.

Re:To become a good C programmer (2011) by AKrumbach on Monday May 02, 2016 @02:37PM (#11614176)
> Can anyone name a language that they've grown to like more the more they learned about it? I would guess maybe only those in the LISP family would make the cut.

Well, personally I've fallen in love with using FORTH for when I'm doing my hardware hacking (mostly on Arduino). I don't think that anybody would call it 'in the LISP family', but the language has similar grammar-extension capabilities, and I adore it for that.

Re:To become a good C programmer (2011) by RodericDay on Sunday May 01, 2016 @02:22PM (#11607250)
I'm not a super genius programmer by any means, but I've had a lot of pleasant surprises learning about the depths of Python.
Re:To become a good C programmer (2011) by renox on Sunday May 01, 2016 @03:35PM (#11607545)
I disagree: no static typing --> annoying runtime errors, no 'use strict'..
Re:To become a good C programmer (2011) by jsmith0295 on Sunday May 01, 2016 @05:14PM (#11607886)
While I like static typing, there's a lot more that goes into making a language good or bad than that. On the whole, python seems pretty good to me. I'd take it over Java 90% of the time.
Re:To become a good C programmer (2011) by mikevm on Sunday May 01, 2016 @06:52PM (#11608214)
I learned to appreciate static typing after "diving into" a large Python codebase. Even with a good IDE (PyCharm), it was freaking hard to understand what the heck was going on. With all the fun in quick prototyping, there's no way I'm going to use a dynamic language for anything serious.
Re:To become a good C programmer (2011) by nstart on Monday May 02, 2016 @12:15AM (#11609165)
If a Python code base that's large carries no tests it can be a nightmare to walk through (I've walked through my own ones that I wrote before I had learnt testing too). Statically types languages are great but if they are also oop I find that unless someone really knows how to hold back on the "make things an interface" mentality you can end up with a large codebase that looks just as crazy as a dynamically typed one.

Point here being that everyone's mileage will vary with dynamic and statically typed languages. But over time as the code base grows, the helpfulness of the language type becomes less (to the point of irrelevance). Instead the value of how cleanly the code has been written and maintained matters much more. Code with good tests, classes that are divided logically, well named methods and variables, etc, should be able to tell you what you are looking for regardless of language type.

Re:To become a good C programmer (2011) by steffan on Monday May 02, 2016 @12:44AM (#11609234)
I have really enjoyed Scala. The more depth I gain in the language, the more I appreciate it. It has the ability to be compact without being overly terse, and is very readable if you don't get too crazy with using symbol overloading and overly-complicated types.
Re:To become a good C programmer (2011) by greydius on Monday May 02, 2016 @05:52PM (#11615986)
> Can anyone name a language that they've grown to like more the more they learned about it?

Haskell