-
-
Save mazdan18/abb1a74f7b2aeec1d4aaecdfa7d0fed4 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
namespace Контроль_выхода | |
{ | |
internal class Program | |
{ | |
static void Main(string[] args) | |
{ | |
string keyWord = "exit"; | |
string answer; | |
Console.WriteLine($"Для выхода наберите {keyWord} "); | |
answer = Console.ReadLine(); | |
while (answer != keyWord) | |
{ | |
Console.WriteLine($"Вы выбрали неправильное слова, наберите {keyWord} "); | |
answer = Console.ReadLine(); | |
} | |
Console.WriteLine("Поздравляем!!, вы выбрались "); | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment