Exemple #1
0
        static void Main(string[] args)
        {
            Marketing abe    = new Marketing("Abe", "CMO");
            Marketing rachel = new Marketing("Rachel", "Marketing Assistant");
            Marketing sarah  = new Marketing("Sarah", "Intern");
            Finance   debbie = new Finance("Debbie", "CFO");

            Company asp = new Company("Appalachia Service Project", DateTime.Now);

            asp.addEmployee(debbie);
            asp.addEmployee(abe);
            asp.addEmployee(rachel);
            asp.addEmployee(sarah);

            foreach (Employee person in asp.marketingDpt)
            {
                Console.WriteLine($"{person.Name} works in the Marketing department and is a {person.JobTitle}");
            }
        }
Exemple #2
0
 public void addEmployee(Finance financeEmployee)
 {
     employees.Add(financeEmployee);
 }