Yahya Hammoud

Yahya Hammoud

  • NA
  • 4
  • 449

how can I make a y/n question

Jun 5 2021 11:22 AM
Console.WriteLine("Penalty (y/n)?");
var num4 = Console.ReadLine();
pen = Convert.ToInt32(num4);
// and if answer is yes I want to give the var a value like 100
//and if answer is no his value will be 0 

Answers (1)