Orientation Lab
Purpose
This lab is the classic introduction to programming. It is a simple Java program to introduce a few basics of the Java programming language. It is important in this lab that you become comfortable compiling and running a Java application.
Key Reading
- 1.4
Requirements
- Attend an Orientation in room 1121 of the Talmage Building
- Create a Java application that prints out the phrase "Hello World! My name is [your name here]."
- Compile and run your Java application in Eclipse.
Requirement Notes
Using Eclipse
- Tutorials for a few common tasks in Eclipse can be found here
Program
- Create an Eclipse workspace for your CS 142 labs
- Create a project for the orientation
- Create a new class named HelloWorld and paste the following code into the Eclipse editor
public class HelloWorld { public static void main(String[ ] args) { System.out.println("Hello World! My name is [insert your name here]."); } }
- Run your program using the run button in Eclipse
- If the console displays the line you entered into your code, you have done everything correctly. If not, ask a TA for assistance.