PersonDemo1.java
1    /* 
2     * Simple program to create and textually display Person 
3     * objects, together with initials and an indication of whether or not the person is a baby boomer. 
4     */
5    
6    package people;
7    
8    public class PersonDemo1 {
9        public static void main(String[] args){
10           Person bd = new Person("Bob Dylan", 5, 24, 1941);
11           Person nr = new Person("Noomi Rapace", 12, 28, 1974);
12           Person pw = new Person("Pharrell Williams", 5, 15, 1973);
13           Person fs = new Person("Frank Sinatra", 3, 8, 1994);
14           Person dk = new Person("Diana Krall", 7, 3, 1963);
15           Person dr = new Person("Damian Randall", 5, 22, 2002);
16   
17           System.out.println(bd + " " + bd.initials() + " " + bd.isBoomer());
18           System.out.println(nr + " " + nr.initials() + " " + nr.isBoomer());
19           System.out.println(pw + " " + pw.initials() + " " + pw.isBoomer());
20           System.out.println(fs + " " + fs.initials() + " " + fs.isBoomer());
21           System.out.println(dk + " " + dk.initials() + " " + dk.isBoomer());
22           System.out.println(dr + " " + dr.initials() + " " + dr.isBoomer());
23   
24       }
25   }
26