a class is a container; it contains: a) a blueprint for objects of that type b) static members (if any) what is an object: an object is a container, a) it contains instance members by members (static or instance) here we mean: a) variables and b) methods (procedures, subroutines, functions) -- class Student { String name; String report() { return this.name; } Student(String name) { this.name = name; } } class Example { public static void main(String[] args) { Student workstudy; workstudy = new Student("Angie"); System.out.println("the student: " + workstudy.report()); workstudy = new Student("Peter"); System.out.println("the student: " + workstudy.report()); int n; n = 5; System.out.println("n has the value: " + n); Example a = new Example(); System.out.println(a); } } -- class Student { String name; String report() { return this.name; } Student(String name) { this.name = name; } public static void main(String[] args) { Student workstudy; workstudy = new Student("Angie"); System.out.println("the student: " + workstudy.report()); workstudy = new Student("Peter"); System.out.println("the student: " + workstudy.report()); int n; n = 5; System.out.println("n has the value: " + n); } } -- // Ten.java class Horse { void talk() { System.out.println("Howdy!"); } } class Unicorn extends Horse { void talk() { System.out.println("Bonjour."); } } class Story { public static void main(String[] args) { Horse a = new Horse(); a.talk(); Unicorn b = new Unicorn(); b.talk(); // b.sing(); Horse c = new Unicorn(); c.talk(); /* Unicorn d = new Horse(); d.talk(); */ } } --