Sovun

Untitled

Sep 21st, 2016
104
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.32 KB | None | 0 0
  1.             int switcher;
  2.             do
  3.             {
  4.                 checkInput = int.TryParse(Console.ReadLine(), out switcher);
  5.                 if ((!checkInput) || ((switcher > 4) || (switcher < 1))) { Console.WriteLine("Неверный формат ввода!"); checkInput = false; }
  6.             } while (!checkInput);
Advertisement
Add Comment
Please, Sign In to add comment