private static void GetMaxCards(int[] max, List <Karta> zw) { for (int i = 0; i < zw.Count; i++) { Karta car = zw[i]; BasicTools.SetMax(ref max[(int)car.Kolor()], (int)car); } }
public static int[] GetHightCards(IEnumerable <Karta> cards) { int[] zw = BasicTools.InitializeTable <int>(4, -1); foreach (var item in cards) { int IndexColor = (int)item.Kolor(); BasicTools.SetMax(ref zw[IndexColor], (int)item); } return(zw); }