Exemplo n.º 1
0
 public HumV(int age, int type, Enlisted E, Officer O)
 {
     this.age  = age;
     this.type = type;
     this.E    = E;
     this.O    = O;
 }
Exemplo n.º 2
0
        static void Main(string[] args)
        {
            Rank      Erank = new Rank('E', 5);
            Rank      Orank = new Rank('O', 2);
            Rifle     R1    = new Rifle();
            Rifle     R2    = new Rifle();
            Generator G     = new Generator();
            Enlisted  E     = new Enlisted(Erank, R2, G);
            Officer   O     = new Officer(Orank, R1, G);
            HumV      V     = new HumV(30, 1165, E, O);

            V.Speak();
        }