Hacker News new | past | comments | ask | show | jobs | submit login

That's precisely why I think Java is a horrible language to start people out in.

Well, not language. Library. It's abstracted to the extreme, and confusing as heck to anyone just starting to learn how to think about how to program.

Start people out in something simple. Ruby can teach bad habits, so don't tell them about monkey patching, but it's so simple it's a great way to hook people, and has simple console / file IO that'll let newbies actually do something with their skills, instead of being glad their project doesn't overflow its array bounds or get stuck in hideous C input handling deathtraps (which flags do you have to reset in the input stream if they start inputting Japanese? I forget...)

Best of all, despite being OO, you don't need a class to start doing things. Something Java gets wrong for beginners.

  #!/usr/bin/env ruby
  puts "hello world"
Classes can wait, they're a whole can of worms that should come after people learn to think clearly enough for a computer to understand them.



If you're burnt out on using Java for introductory courses, consider using Groovy. (http://groovy.codehaus.org/). It takes a lot of the pain and boilerplate code out of java, making it easier for students to focus on what they're actually doing and not writing "public static void main String args" all of the time.

Similar to your example, this is a valid groovy program:

println "Hello!"

But, unlike Python or Ruby, you're still in the Java world so migrating back to to pure Java is a lot easier. Though, the shrieks of pain you'll endure when you explain why they now have to write constructors or getters and setters might hurt. :-)


Have seen it, but never used it. It looks decently active on the forums, despite the home page showing an award from 2007 (and looking older than that)... how's the community / code health? On something like a .NET-to-Ruby/Python scale? I'll keep it in mind for any future Java necessities.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: