public decimal InjuryRatio() { int players = 0; int injuries = 0; IDictionaryEnumerator myEnumerator = TheHt.GetEnumerator(); while (myEnumerator.MoveNext()) { NFLPlayer p = (NFLPlayer)myEnumerator.Value; if (p.IsActive()) { players++; } if (p.IsInjured()) { injuries++; } } decimal ratio = Ratio(injuries, players); RosterLib.Utility.Announce(string.Format("Injury Ratio:- Injuries {0} players {1} Ratio {2:###.#}%", injuries, players, ratio * 100.0M)); return(ratio); }