public void Count(string element) { int counter = 0; for (int i = 0; i < workList.Count; i++) { if (workList[i] == element) { counter++; } } ConsoleManager.WriteLine(counter.ToString()); }
public void Listen() { string commandInput = ConsoleManager.Read(); while (commandInput != EndCommand) { try { this.ParseCommand(commandInput); } catch (ArgumentException ex) { ConsoleManager.WriteLine(ex.Message); } commandInput = ConsoleManager.Read(); } }
public void PrintWorkingList() { ConsoleManager.WriteLine(string.Join(" ", this.workList)); }