CS 1711 Recitation Laboratory 1:
Introduction to the programming environment

Objectives:

Hand-in Requirements:

A zip file of your eclipse project which will be graded as follows: All projects and laboratories will be submitted electronically through Blackboard. Zip up your entire project directory. (Right click on the project folder and follow the SentTo link.) You should upload your zipped file in Blackboard under the Submissions menu. You can create the errors.txt file in a text editor such as WordPad. Any files that you create should be in the top level project directory, lab01.

Overview:

The goal of this laboratory is for you to get your account set up and to understand how to run simple Java programs using eclipse. It is important that you get all account problems resolved in the first two weeks of class. You will have an account on the CS network that works on the Windows and Linux (Unix) machines in the Computer Science Laboratories. We will mainly be using Windows machines for this course. The schedule for the Java lab can be found at http://www.cs.utsa.edu/~javalab/lab/schedule.html. During many the hours that the Java lab is open, tutors are available to help you. You can get as much help as you want in completing the laboratories. We encourage you to get help and to keep up with the course, especially at the beginning when it is easy to fall behind.

Part I: Running some simple programs

In this course you will be using Eclipse Integrated Development Environment (IDE) to develop your Java programs. Eclipse is one of the most popular IDEs used in industry. Your presenter will take you through the steps for creating a simple Eclipse project called lab01.

Part II: Error analysis

In this part of the laboratory, you will explore how the Java compiler reacts to various changes in the HelloWorld class. Make each of the following modifications to your original HelloWorld class. For each modification, indicate whether or not it causes an error. Make a file called error.txt in eclipse for your analysis. Do this as follows:
Select File -> New -> File.
In the directory tree that appears, click on lab01 and enter the file name error.txt. Click Finish. An empty file should appear under the tab error.txt. Set the Name to error and the Type to txt. Paste the following list of changes into your file. If the modification is okay, write "No error" next to the change. If the modification gives an error, there will be a red X to the left of the line with the error and a small pink rectangle to the right. Hover your mouse over the X or the rectangle to display the error message.
Type the error in your error.txt file and write a brief explanation of why it is an error.

Change 1: Change main to man.
Change 2: Remove the semicolon from the end of the println statement.
Change 3: Change HelloWorld to Hello world in the class definition line.
Change 4: Change simpleproject to simple.
Change 5: Change my name to My name.
Change 6: Remove the last brace from the program.
Change 7: Remove the first quote (").
Change 8: Remove the second quote(").
Change 9: Change println to printline.
Change 10: Remove the word static.

(You may want to make a copy of your original source in a WordPad file and paste it back each time.)

Part III: On your own