@@ -0,0 +1,2198 @@
+//January 24, 2013%0A//%09Word about Style%0A//%09%09Structure your code properly%0A// %09%09Eliminate redundancy%0A//%09%09Use comments%0A//%09%09Use spaces judiciously and consistently %0A//%09%09Indent properly%0A//%09This ensures interoperability of code going forward%0A//%0A// Memory: %0A//%09* RAM is divided into many cells, each cell has an address.  Each cell has a special # of bits (8, one byte)%0A//%09* bit can represent 2 values: 0 or 1%0A//%0A// What do these bits represent?%0A//%09* 2%5E8 = 256%0A// 1 2 3 4 5  6  7  8%0A// 1 2 4 8 16 32 64 128%0A// 1 0 0 1 1  0  1  0%0A// 1+8+16+64= 89 OR letter Y%0A// %0A//%0A// Type Systems%0A// * category or set of values and operations defined on those values%0A// * helps us know what data is %0A//%0A// In Java: %0A// Numeric Primitive Data Types:%0A// * Integer nubers (byte, short, int, long)%0A// %09%09* Different types = ranges and precisons%0A// * Real (floating) numbers (float, double)%0A// %09%09* Can a computer store all real numbers in a range?  No.  Infinite real numbers! %0A// Every data item has a type%0A// * %224 is type int%22%0A// * Real (floating point) literal (e.g. -1.236.12e23) is default type double%0A// %0A// Variables - piece of computer memory with a nae and a type%0A// %09* like a speed dial%0A// %09%09Steps: 1) Declare, 2) assign values, 3) use%0A//%0A// %09%09Syntax: %3Ctype%3E %3Cname%3E%0A// %09%09ex. %09int x%0A// %09%09%09%09x = 3%0A%09%09%09// ** A variable can only store a value of its own type%0A%09%09%09// %0A%09%09%09// ex.%09myGPA = 1.0 + 2.25 (float)%0A%09%09%09//%0A%09%09%09// Questions%0A%09%09%09// * To represent # of students at Yale, which numeric data type variable do you use? %0A%09%09%09//%09%09Answer: short/int%0A%09%09%09//%0A%09%09%09// * To represent # of World poplation?%0A%09%09%09//%09%09Answer: long (largest number int can store is 2 billion)%0A%09%09%09//%0A%09%09%09// * To represent pi?%0A%09%09%09//%09%09Use double (not float)%0A%09%09%09// %0A%09%09%09// Patriot Missile Failure %0A%09%09%09// * Precision of computer error can mess things up%0A%09%09%09//%0A%09%09%09// Java uses Unicode, superset of ASCII (16 bits, 2 byes per character - international)%0A//%0A// Boolean: represents local value, true or false%0A// Reasonable Operations%0A%09// * each type systemm has its own kind of operations (see slides!!)%0A%09// ex. char - characters - literal values - compare operations%0A// Most operations are intuitive %0A//%09Ordering%0A%0Apublic class myGPA %7B%0A%09public static void main(String)%0A%7D%0A%0A%0A%0A%0A

Create Jan21.java