Exercise 1: Displaying Message Using Inheritance
Explore how to implement inheritance in C# by creating an Animal parent class and derived classes for Zebra and Dolphin. Learn to set properties and return descriptive messages using methods, helping you grasp core OOP concepts in C#.
We'll cover the following...
We'll cover the following...
Problem Statement
The code below has:
- A parent class named
Animal.- Inside it define:
nameageset_value(int a,string b)method:- takes
ageandname
- takes
- Inside it define: