public static void Main()
Console.WriteLine("Welcome to Game 21");
Random rG = new Random();
Console.WriteLine("How many cards do you want to be dealt (2-4)? ");
int numofcards = Convert.ToInt32(Console.ReadLine());
int p1c1 = rG.Next(1,11);
int p1c3 = rG.Next(1,11);
int p1c4 = rG.Next(1,11);
Console.WriteLine("Your First Card is: " + p1c1);
Console.WriteLine("Your Second Card is: " +p1c2);
else if (numofcards == 3){
Console.WriteLine("Your First Card is: " + p1c1);
Console.WriteLine("Your Second Card is: " + p1c2);
Console.WriteLine("Your Third Card is: " + p1c3);
pScore = p1c1 + p1c2 + p1c3;
Console.WriteLine("Your First Card is: " + p1c1);
Console.WriteLine("Your Second Card is: " + p1c2);
Console.WriteLine("Your Third Card is: " + p1c3);
Console.WriteLine("Your Forth Card is: " + p1c4);
pScore = p1c1 + p1c2 + p1c3 +p1c4;
Console.WriteLine("Your Score: " + pScore);
Console.WriteLine(" ",25);
Console.WriteLine("Computer's First Card is: " + dc1);
Console.WriteLine("Computer's Second Card is: " + dc2);
else if (numofcards == 3){
Console.WriteLine("Computer's First Card is: " + dc1);
Console.WriteLine("Computer's Second Card is: " + dc2);
Console.WriteLine("Computer's Third Card is: " + dc3);
dScore = dc1 + dc2 + dc3;
Console.WriteLine("Computer's First Card is: " + dc1);
Console.WriteLine("Computer's Second Card is: " + dc2);
Console.WriteLine("Computer's Third Card is: " + dc3);
Console.WriteLine("Computer's Forth Card is: " + dc4);
dScore = dc1 + dc2 + dc3 + dc4;
Console.WriteLine("Computer's Score: " + dScore);
if (pScore > 21 && dScore > 21)
Console.WriteLine("It is a Draw!");
else if (pScore <= 21 && dScore >21)
Console.WriteLine("Player wins");
else if (dScore <= 21 && pScore >21)
Console.WriteLine("Computer wins");
else if (dScore > pScore && dScore <= 21)
Console.WriteLine("Computer wins");
else if (pScore > dScore && pScore <= 21)
Console.WriteLine("Player wins");