Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- namespace Max_Number
- {
- class Program
- {
- static void Main(string[] args)
- {
- string input = Console.ReadLine();
- int maxNum = int.MinValue;
- while (input!="Stop")
- {
- int number = int.Parse(input);
- if (number > maxNum)
- {
- maxNum = number;
- }
- input = Console.ReadLine();
- }
- Console.WriteLine(maxNum);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement