Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- namespace ClatiteGurmand
- {
- class Program
- {
- static void Main(string[] args)
- {
- int i = 1, clatite = 0, max = 0;
- while (i < 11)
- {
- Console.Write("Gurmandul {0} a mancat: " , i);
- clatite = Convert.ToInt32(Console.ReadLine());
- i++;
- }
- int step = 0;
- for (i = 1; i < clatite; i++)
- {
- if (clatite > max)
- {
- max = clatite;
- step = i;
- }
- }
- Console.WriteLine("Maximul de clatite " + max + " este mancat de gurmandul {0}", step);
- Console.ReadKey();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement