Permalink
Cannot retrieve contributors at this time
Name already in use
A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
School/C# - Beginner (Denis)/Lesson 60/lesson_60.cs
Go to fileThis commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
47 lines (41 sloc)
731 Bytes
This file contains 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
public partial class Person | |
{ | |
public void Move() | |
{ | |
Console.WriteLine("I am moving"); | |
} | |
} | |
public partial class Person | |
{ | |
public void Eat() | |
{ | |
Console.WriteLine("I am eating"); | |
} | |
} | |
class Program | |
{ | |
static void Main(string[] args) | |
{ | |
Person tom = new Person(); | |
tom.Move(); | |
tom.Eat(); | |
Console.ReadKey(); | |
} | |
} | |
public partial class Person | |
{ | |
partial void DoSomethingElse(); | |
public void DoSomething() | |
{ | |
Console.WriteLine("Start"); | |
DoSomethingElse(); | |
Console.WriteLine("Finish"); | |
} | |
} | |
public partial class Person | |
{ | |
partial void DoSomethingElse() | |
{ | |
Console.WriteLine("I am reading a book"); | |
} | |
} |