public void quack() { IEnumerator iterator = quackers.GetEnumerator(); while (iterator.MoveNext()) { Quackable quacker = (Quackable)iterator.Current; quacker.quack(); } }
public void quack() { var enumerator = quackers.GetEnumerator(); while (enumerator.MoveNext()) { Quackable quacker = enumerator.Current; quacker.quack(); } }
public void quack() { IEnumerator <Quackable> enumerable = quackers.GetEnumerator(); while (enumerable.MoveNext()) { Quackable quacker = enumerable.Current; quacker.quack(); } }
public void quack() { duck.quack(); numberOfQuacks++; }
private void simulate(Quackable duck) { duck.quack(); }
public void quack() { m_duck.quack(); m_numberOfQuacks++; }
private void simulate(Quackable q) { q.quack(); }
public void quack() { duck.quack(); numberofQuack++; }