You will write a program that checks whether the user entered either yes or no.
All other inputs will be considered incorrect.
To disregard the difference in case, you convert the input to lowercase letters.
The condition used is a compound condition.
It consists of two partial conditions connected using the conditional OR operator, ||
using System; class Program/* w w w .ja va 2s . c o m*/ { static void Main(string[] args) { // Input Console.Write("Do you love me? "); string input = Console.ReadLine(); // Evaluating string inputInSmall = input.ToLower(); if (inputInSmall == "yes" || inputInSmall == "no") { Console.WriteLine("OK."); } else { Console.WriteLine("wrong input!"); } } }