using System.Collections.Generic;
using System.Threading.Tasks;
namespace ConsoleApplication2
public static void Main(string[] args)
police pl = new police();
call911 c911 = new call911();
c911.callforHelp += pl.oncallto911;
c911.notification("Sample Address");
public void oncallto911(object sender, EmergencyInfo e)
Console.WriteLine("Call from " + e.Address);
public event EmergencyEvent callforHelp;
public void notification(string msg)
callforHelp(this, new EmergencyInfo(msg));
public delegate void EmergencyEvent(object sender, EmergencyInfo e);
public class EmergencyInfo : EventArgs
public string Address { get; set; }
public EmergencyInfo(string address)