Created
November 20, 2012 02:36
-
-
Save slimbo/4115564 to your computer and use it in GitHub Desktop.
Hit the Bits! - BugEater Example in C#
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| interface BugEater | |
| { | |
| void consume(Bug bug); | |
| } | |
| class Aardvark : BugEater | |
| { | |
| public void consume(Bug bug) | |
| { | |
| // code goes here | |
| } | |
| } | |
| class VenusFlyTrap : BugEater | |
| { | |
| public void consume(Bug bug) | |
| { | |
| // code goes here | |
| } | |
| public void consume(Water water) | |
| { | |
| // code goes here | |
| } | |
| public void consume(Sunlight sunlight) | |
| { | |
| // code goes here | |
| } | |
| public void grow() | |
| { | |
| // code goes here | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment