Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public interface IBall
- {
- }
- public class BilliardBall : IBall
- {
- }
- public abstract class Sport
- {
- protected abstract IBall Ball { get; }
- }
- public class Billiards : Sport
- {
- protected override IBall Ball
- {
- get { return new BilliardBall(); }
- }
- }
Add Comment
Please, Sign In to add comment