实现效果:
知识运用:(泛型类的继承)
class DerivedClass<类型参数T>:BaseClass<类型参数T>
{
}
实现代码:
class BstuInfo<T> { public T Num; public T Name; public T Sex; public T Age; public T Birthday; public T Salary; } class HstuInfo<T>:BstuInfo<T> { public T Chinese; public T Match; public T English; }
原文:https://www.cnblogs.com/feiyucha/p/10089031.html