Write an abstract class called A and a second class called B which inherits from A. Class A will have an abstract void callMe() method which does not take any parameters. Class A will also have a void method called callMeToo() which takes no parameters and prints the message "This is a concrete method". Class B will also have a void callMe() method which prints the message "B's implementation of callMe". In your main program, create a B object and call the callMe() and callMeToo() methods using that object.

Microsoft Visual C#
7th Edition
ISBN:9781337102100
Author:Joyce, Farrell.
Publisher:Joyce, Farrell.
Chapter10: Introduction To Inheritance
Section: Chapter Questions
Problem 20RQ
icon
Related questions
Question

Do in c#

Write an abstract class called A and a second class called B which inherits from A.
Class A will have an abstract void callMe() method which does not take any
parameters. Class A will also have a void method called callMeToo() which takes no
parameters and prints the message " This is a concrete method'.
Class B will also have a void callMe() method which prints the message "B's
implementation of callMe".
In your main program, create a B object and call the callMe() and callMeToo()
methods using that object.
Transcribed Image Text:Write an abstract class called A and a second class called B which inherits from A. Class A will have an abstract void callMe() method which does not take any parameters. Class A will also have a void method called callMeToo() which takes no parameters and prints the message " This is a concrete method'. Class B will also have a void callMe() method which prints the message "B's implementation of callMe". In your main program, create a B object and call the callMe() and callMeToo() methods using that object.
Expert Solution
steps

Step by step

Solved in 4 steps with 2 images

Blurred answer
Knowledge Booster
Reference Types in Function
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Microsoft Visual C#
Microsoft Visual C#
Computer Science
ISBN:
9781337102100
Author:
Joyce, Farrell.
Publisher:
Cengage Learning,
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT