コード例 #1
0
        static void Main(string[] args)
        {
            Pravougaonik p  = new Pravougaonik(2, 3);
            Krug         k  = new Krug(4);
            Kvadrat      kv = new Kvadrat(5);

            Console.WriteLine(p);
            Console.WriteLine(k);
            Console.WriteLine(kv);
        }
コード例 #2
0
 public Valjak(double r, double h)
 {
     this.b = new Krug(r);
     this.m = new Pravougaonik(b.GetO(), h);
 }