Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- interface IMyInterface
- {
- void MethodToImplement();
- void MethodYgLain();
- }
- class ClassKita : IMyInterface
- {
- public void MethodToImplement()
- {
- Console.WriteLine("MethodToImplement() dieksekusi.");
- }
- public void MethodYgLain()
- {
- Console.WriteLine("MethodYgLain() dieksekusi.");
- }
- }
- //Updated 25 August 14
- class Program
- {
- static void Main()
- {
- IMyInterface im = new ClassKita(); // Create instance.
- im.MethodToImplement(); // Call method on interface.
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment