Introduction to Java

Work through these slides. As you read, think about and answer the questions at the bottom of each page. These will be your first experience with Java, so make sure you follow each step closely.

17. Result of Running the Example Java Program

Answer:

The example Java program wrote the words "Hello World!" in the command interpreter window.

Result of Running the Example Java Program

Figure05-9

The picture shows my system when everything has worked correctly (which happens every time, of course).

Your program may not have run correctly. It is possible that you did not type in exactly the right characters. Spaces don't particularly matter. But check especially characters like [ and { and ( and ". You have to use the correct ones. Check that upper case and lower case characters match the sample program.

Fuss around for a while to get the program to work. If you just can't get it to work, give up and move on. Probably there is some trivial detail that you have overlooked and will see clearly later on. This happens all the time in programming.

If everything worked out perfectly, then go back and do something wrong. This will help you understand what happened later on when you unintentionally do something wrong.


Question 17:

Had enough, for now?