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