public void Visit(IElement element) { Kid kid = (Kid)element; Console.WriteLine($"Salesman: {this.Name} gave the school bag to the child {kid.KidName}"); }
public void Visit(IElement element) { Kid kid = (Kid)element; Console.WriteLine($"Doctor: {this.Name} did the health checkup of the child: {kid.KidName}"); }