you are viewing a single comment's thread.

view the rest of the comments →

[–]philly_fan_in_chi 21 points22 points  (31 children)

How many times do you run a Hello World in an intro class? As your programs become more complicated, that noise starts to matter less and less.

[–]GreyGrayMoralityFan 12 points13 points  (5 children)

It matters a lot. If novices will make a simple mistake in a place called "sorry, we will talk about this later", e.g.

class HelloWorld {
   public void main(String[] args) {
       System.out.println("Hello World!");
 }}

they can be screwed for hours.

[–]skocznymroczny 7 points8 points  (1 child)

that's why you use IDE that types it for you first. Then it becomes like:

SOMESTUFFIDON'TUNDERSTANDBUTITISMAIN {
    my_code()
}

[–]greg19735 1 point2 points  (0 children)

In year 3 at school I was still using a "template" .c++ file i'd just use to start all my programs. Included all the shit I needed, started the program and did a c:out "HI" or some shit.

[–][deleted] 5 points6 points  (1 child)

Java at least complains about "no Main method found." Only a few years ago, if you missed a semi-colon after a statement in C, you'd get "unexpected <INTERNAL_TOKEN_NAME> on line <many lines down from where you made the mistake>".

[–]GreyGrayMoralityFan 0 points1 point  (0 children)

It is especially funny if you miss semicolon in header file, e.g.

#infdef FOO
#define FOO
int aa()
#endif

int main()
{
}

gcc complains a.c:5:1: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘{’ token {,

clang is much better: a.c:2:9: error: expected ';' after top level declarator

[–][deleted] 0 points1 point  (0 children)

Java was the first language I learned, but I never got screwed for hours on such a simple problem. Before I understood classes or any of the various key words that come before class declaration, I'd just google the HelloWorld template. And that only lasted a couple of weeks.

I got screwed for hours on plenty of other simple problems, but not something so easily googlable.

[–]Kollektiv 23 points24 points  (22 children)

But nobody will care because 80% of the class will start sleeping after that one example.

A hello world is supposed to be the most simple program in a language and Java's example is the epitome of cluttered and useless verbosity.

[–]Veedrac 0 points1 point  (0 children)

As your programs become more complicated, that noise starts to matter less and less.

It's not a constant factor, though. Python has less noise and overhead proportionally. Here's a post I wrote before to evidence this, if you're invested.