Yurttas/PL/OOL/Java/F/04/03/10/01/Q00.java

From ZCubes Wiki
Jump to navigation Jump to search
 1/**
 2 *  Copyright(C) 1998
 3 *  All Rights Reserved. Salih Yurttas, ZCubes, BitsOfCode Software Systems, Inc..
 4 *
 5 *  Permission to use, copy, modify, and distribute this
 6 *  software and its documentation for EDUCATIONAL purposes
 7 *  and without fee is hereby granted provided that this
 8 *  copyright notice appears in all copies.
 9 *
10 *  @date   : January 1, 1998.
11 *  @author : Salih Yurttas.
12 */
13
14
15public class Q00 {
16
17  public static void main(String[] args) {
18
19    Q q1 = new Q();
20
21    System.out.println("initial values after default construction -Q() /");
22
23    q1.output();
24
25    System.out.println();
26
27    q1.setI1(2);
28
29    System.out.println("accessor after mutator /");
30    System.out.println(q1.getI1());
31
32    System.out.println();
33
34    Q q2 = new Q(9);
35
36    System.out.println("initial values after default construction -Q() /");
37
38    q2.output();
39
40    System.out.println();
41
42    q2.setI1(3);
43
44    System.out.println("accessor after mutator /");
45    System.out.println(q2.getI1());
46
47  }
48
49}