/home/mbilodea/NetBeansProjects/CS1/src/people/PersonDemo2.java
 1 /*
 2  * PersonDemo1 is a simple program to create and technically display Person
 3  * objects, together with initials and an indication of whether or not the
 4  * person is a baby boomer, with such data being contained by an array.
 5  */
 6 package people;
 7 
 8 /**
 9  *
10  * @author mbilo
11  */
12 public class PersonDemo2 {
13 
14     /**
15      * @param args the command line arguments
16      */
17     public static void main(String[] args) {
18         // CREATE AN ARRAY OF PERSON OBJECTS OF SIZE 6 AND FILL IT WITH THE DATA
19         Person[] people = new Person[6];
20         people[0] = new Person("Bob Dylan",5,24,1941);
21         people[1] = new Person("Noomi Rapace",12,28,1974);
22         people[2] = new Person("Pharrel Williams",4,5,1973);
23         people[3] = new Person("Frank Sinatra",12,12,1915);
24         people[4] = new Person("Diana Krall",11,16,1964);
25         people[5] = new Person("Mathew Bilodeau",1,27,2000);
26         
27         //  USE A FOR LOOP TO DISPLAY THE SIX PERSON OBJECTS IN THEIR TECXTUAL FORM
28         for (int i = 0; i <= people.length-1; i++) {
29             System.out.println(people[i] + " " + people[i].initials() + " " + people[i].isBoomer());
30         }
31     }
32     
33 }
34