Exemple #1
0
        public List <Kart> Dagit(int[] deste, int adet)
        {
            List <Kart> El = new List <Kart>();

            for (int i = sayac; i < sayac + adet; i++)
            {
                Kart yeni = new Kart(deste[i]);
                El.Add(yeni);
            }
            sayac += adet;
            return(El);
        }
Exemple #2
0
 private void Sirala(List <Kart> hand)
 {
     for (int i = 0; i < hand.Count - 1; i++)
     {
         for (int j = i + 1; j < hand.Count; j++)
         {
             if (hand[i].sayi > hand[j].sayi)
             {
                 Kart temp = hand[i];
                 hand[i] = hand[j];
                 hand[j] = temp;
             }
         }
     }
 }