예제 #1
0
파일: Person.cs 프로젝트: mstaessen/Primers
 public bool Likes(Person other)
 {
     return Friends.Contains(other);
 }
예제 #2
0
파일: Person.cs 프로젝트: mstaessen/Primers
 public void SetLikes(Person other)
 {
     Friends.Add(other);
 }
예제 #3
0
파일: Spot.cs 프로젝트: mstaessen/Primers
 public int ScoreIfPersonSwappedWith(Person other)
 {
     return Neighbours.Values.Count(neighbour => other.Friends.Contains(neighbour.Person));
 }