Check out example codes for "inheritance in c#". It will help you in understanding the concepts better.
Code Example 1
// Parent Class
public class A
{
public void Method1()
{
// Method implementation.
}
}
// inherit class A in class B , which makes B the child class of A
public class B : A
{ }
public class Example
{
public static void Main()
{
B b = new B();
// It will call the parent class method
b.Method1();
}
}
Code Example 2
//example
class derived: super
{private int arg;
// constructor
public derived(int arg, int super_arg): base(super_arg)
{
this.arg=arg;
this.super_arg=super_arg;
}
}
Learn ReactJs, React Native from akashmittal.com