Lab goal: Take a pre-class survey, send email, provide information about yourself, run a java program.

 

 

I.                 Pre-class-Survey  Click Here

This is a pre-class survey so it is expected that you will be unfamiliar with some of the content. In those cases, you can just skip to the next question. Do not agonize, if you cannot decide between 2 answers just make an educated guess. The number of correct questions will not determine your grade, however you should do the best you can.

 

II.            E-Mail and Information

1.   Before tomorrow at 11:59pm, send an email to garrisonc@winthrop.edu that includes:

A. The standard subject line: CSCI 151, Lab Time, Specific Subject, Student Name(s).

§  Ex: CSCI151_2:00_Lab1__FirstName LastName

B. The preferred name you would like us to use to address you.

C. Your computer experience. As a user, e.g., games, word processing. As a programmer, e.g. Java, Visual Basic, C++. Whatever you have if any.

D. Your Interests. Tell me something that will help me remember you.

E. Add the results of IV below before sending your email.

 

 III. Purchase your textbook Today!  Programming in Java. Sign in or create an account at zyBooks.com. Enter provided zyBook code . The book is available at zyBooks.com or the bookstore. This book is required and will be used for readings and to complete at least 30% of the course grade.Complete required reading and activities before next class.

 

IV.         Java Introduction (complete in one of the campus labs and send results in the email of part II)

1.   Make a directory (folder) on your Z drive for work you will do in this class. I recommend calling it csci151. If you're not sure how to do this, start by double clicking on the Z drive icon on your desktop and then click to add a new folder.

2.   Create a new subdirectory of your csci151 directory called quote.

3.   Download Quote.java into the subdirectory you created.

    Note: Save it, do not open it yet. If you open it first the system assigns a different name to it and that will mess you up later. If you do this correctly you should see Quote.java as the only file in the quote directory. (You may just see the name Quote with a note beside it that it's a .java file. That's good too.)

4.   At the bottom left of the keyboard find the <windows> key. It's the one with the little flag on it. Press <windows><r>

5.   In the space provided type cmd. This will bring up a black "command shell"

6.   In the command shell change drives to get to your Z drive. Just type z: if you need to do this.

7.   Change directories to get to your quote directory.

o    E.g. something like cd csci151\quote should work. Or you could do this in two steps: cd csci151 and then cd quote. "cd" stands for "change directory". If you type dir (for directory) you'll see the same files in the command shell as you saw graphically before.

8.   Type javac Quote.java to compile the code. Note that the upper case Q matters. When you're dealing with Java, you have to be careful of upper and lower case.

.       Think of Java as a language that's halfway between what a human can understand and what a computer can understand. With practice, humans can read and write Java code, thus creating what you will soon see in Quote.java. But the computer speaks a different language. So javac translates Quote.java into code the computer can understand (but humans can't). This code is stored in a new file called Quote.class.

·       Check the csci151/quote directory by typing dir to see the new Quote.class file.

·       Now that that Quote.java has been compiled into a java class, it can be run as a java program.

9.   Type java Quote to run the program.

10.                     Show me what is printed to the screen. If you do not finish during the lab, send a snippet of the results in the email of part II.