Demographics - public static void main(String args Person...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
//******************************************************************** // Demographics.java Author: Lewis and Loftus // // Solution to Programming Project 7.5 //******************************************************************** / public class Demographics { p //------------------------------------------------------------------ // Driver for creating demographics //------------------------------------------------------------------
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: public static void main(String args) { Person demos = new Person[4]; demos[0] = new Person(8, "Utah"); demos[1] = new Student(25, "New Mexico", "University of New Mexico"); demos[2] = new ForeignStudent(19, "Ohio", "Ohio State", "India"); demos[3] = new Employee(38, "Delaware", "Tile Setter", 40000); for (int i=0; i<demos.length; i++) System.out.println(demos[i] + "\n---------------------\n"); } }...
View Full Document

{[ snackBarMessage ]}

Ask a homework question - tutors are online