08-30 Class Notes CS 107

08-30 Class Notes CS 107 - 08-30 Class Notes CS 107 Monday,...

Info iconThis preview shows pages 1–3. Sign up to view the full content.

View Full Document Right Arrow Icon
In-lab quiz based on Chapter 1. For Program #1 you should be half-way done by now. Announcements: Questions? Last Time: Started looking at writing simple Java programs using Eclipse Fundamentals of a simple Java program: comments, output, variables, assignment, arithmetic, strings, precedence, if statement, while statement Today: http://logos.cs.uic.edu/Examples%20And%20Notes/notes/Java/index.htm See PlanetWeights examples versions 1-4 shown below Simple Java program examples taken from: Version 1 : A simple program, comments, semicolon, output /** * Weight Calculator > Essentials1.java * * Displays your weight on the moon using console output. * Illustrates a basic program, multi-line comments, output. * * @author Dale Reed 08-30 Class Notes CS 107 Monday, August 30, 2010 8:27 AM 107 Fall 2010 Page 1
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
* * Displays your weight on the moon using console output. * Illustrates a basic program, multi-line comments, output. * * @author Dale Reed */ public class Essentials1 { public static void main(String[] args) { // Prints "On the moon you weight 30 pounds." to the console. System.out.println("On the moon you weight 30 pounds."); } } /* Output: On the moon you weight 30 pounds. */ Version 2 : Variables, assignment, arithmetic, string concatenation /** * Weight Calculator > Essentials2.java * * Displays your calculated weight on the moon using console output. * Illustrates variable declarations, identifiers, initialization, assignment,
Background image of page 2
Image of page 3
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 02/10/2012 for the course COP 2271 taught by Professor Reed during the Fall '10 term at University of Central Florida.

Page1 / 4

08-30 Class Notes CS 107 - 08-30 Class Notes CS 107 Monday,...

This preview shows document pages 1 - 3. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online