public string GetPlacement(WeighIn weighIn) { if (weighIn == null) { return("Did Not Weigh In"); } int placement = weighIn.Placement; string ordinal = "th"; if ((placement % 100) / 10 != 1) { switch (placement % 10) { case 1: ordinal = "st"; break; case 2: ordinal = "nd"; break; case 3: ordinal = "rd"; break; } } return($"You Placed {placement}{ordinal} Out Of {WeighIns.Count}"); }
public string GetWeight(WeighIn weighIn) { if (weighIn == null) { return("Did Not Weigh In"); } return($"You Caught {weighIn.ToString()}"); }