Professional Documents
Culture Documents
Awwal 2
Awwal 2
}
string message = (totalPoint >= 20 && totalPoint <= 24) ? "You won
Congratulations" : "Sorry try again";
// ======= PRIZES =======
// if (totalPoint >= 10 && totalPoint <= 13)
// {
// Console.WriteLine("Congratulations!!! :)\nYou get a balloon");
// // System.Console.WriteLine($"Total score: {totalPoint}");
// }
// else if (totalPoint >= 14 && totalPoint <= 16)
// {
// Console.WriteLine("Congratulations!!! :)\nYou get an Exercise book");
// }
// else if (totalPoint == 17)
// {
// Console.WriteLine("Congratulations!!! :)\nYou get a 5000mah power
bank");
// }
// else if (totalPoint == LUCKYNUMBER)
// {
// Console.WriteLine("Congratulations!!!\nYou rolled the lucky number");
// Console.WriteLine("You win a Samsung A24");
// }
// else if (totalPoint >= 18 && totalPoint <= 20)
// {
// Console.WriteLine("Congratulations!!! :)\nYou win a Sliver bird Cinema
Ticket");
// }
do
{
System.Console.Write("Do you want to continue type y to continue and n to
end: ");
userAction = Console.ReadLine()!;
} while (!userAction.Equals(yes, StringComparison.OrdinalIgnoreCase) && !
userAction.Equals(no, StringComparison.OrdinalIgnoreCase));
if (userAction != yes)
{
flag = false;
}
}