static void Main(string[] args) { Triangle triangle = new Triangle(); InputShowTriangle inputShowT = InputShowDataT; inputShowT(triangle); Rectangular rect1 = new Rectangular(); InputShowRectangular inputShow = InputShowDataR; inputShow(rect1); }
static Rectangular InputShowDataR(Rectangular rect) { rect.Input(); Console.WriteLine(rect.ToString()); return(rect); }