Add project files.

This commit is contained in:
marthanelentianita
2025-05-09 19:00:21 +02:00
parent 41b0c42da9
commit ed07237c41
8 changed files with 230 additions and 0 deletions

29
OsztoProgram/Csomag.cs Normal file
View File

@@ -0,0 +1,29 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace OsztoProgram
{
internal class Csomag
{
public Kartyalap[] Lapok;
public Csomag()
{
Lapok = new Kartyalap[52];
//kártyalapok létrehozása:
string[] színek = { "pikk", "kör", "káró", "treff" };
string[] ertekek = { "2", "3", "4", "5", "6", "7", "8", "9", "10", "J", "Q", "K", "A" };
int lapindex = 0;
foreach (string szín in színek)
{
foreach(string ertek in ertekek)
{
Lapok[lapindex] = new Kartyalap(szín, ertek);
lapindex++;
}
}
}
}
}