1/**
2 * Copyright(C) 2003
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 : September 1, 2003.
11 * author : Salih Yurttas.
12 *
13 * A.cs
14 */
15
16
17using System;
18using System.Collections;
19
20public class A : IA
21{
22 private int SA1;
23 private ArrayList A1;
24
25 private int SA2;
26 private string A2;
27
28 public int GetSA1()
29 {
30 return A1.Count;
31 }
32
33 public ArrayList GetA1()
34 {
35 return A1;
36 }
37
38 public void SetA1(ArrayList A1)
39 {
40 this.A1 = A1;
41 }
42
43 public int GetSA2()
44 {
45 return A2.Length;
46 }
47
48 public string GetA2()
49 {
50 return A2;
51 }
52
53 public void SetA2(string A2)
54 {
55 this.A2 = A2;
56 }
57
58 public A()
59 {
60 SA1 = 2;
61 A1 = new ArrayList();
62
63 for(int i=0; i<SA1; ++i)
64 A1.Add(1);
65
66 SA2 = 4;
67 A2 = new string('y',
68 SA2);
69 }
70
71 public A(int SA1,
72 int[] vi,
73 int SA2,
74 char vc)
75 {
76 this.SA1 = SA1;
77 ArrayList a1 = new ArrayList();
78
79 for(int i=0; i<SA1; ++i)
80 A1.Add(vi[i]);
81
82 this.SA2 = SA2;
83
84 A2 = new string(vc,this.SA2);
85 }
86
87 public void Output()
88 {
89 foreach(int i in A1)
90 Console.WriteLine(i);
91
92 Console.WriteLine(A2);
93 Console.WriteLine();
94 }
95}