C Sharp (C#) - Polymorphism and Abstract Classes
Analyze the following code and find the error:
abstract class Instrument {
public abstract void Play();
}
class Piano : Instrument {
public override void Play() {
System.Console.WriteLine("Playing piano");
}
}
class Guitar : Instrument {
public void Play() {
System.Console.WriteLine("Playing guitar");
}
}