Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int[] i = new int[10];
- int[] del = new int[10];
- int ultra = int.MaxValue;
- int prumer = 0;
- Console.WriteLine("Zadej 10 čísel: ");
- for (int a = 0; a < 10; a++)
- {
- i[a] = Convert.ToInt32(Console.ReadLine());
- if (i[a] % 3 == 0) { del[a] = i[a]; }
- }
- Console.Clear();
- for (int x = 0; x < 10; x++)
- {
- if (del[x] != 0)
- {
- Console.WriteLine("{0} je dělitelné 3", del[x]);
- }
- if (i[x] < ultra) ultra = i[x];
- prumer = prumer + i[x];
- }
- Console.WriteLine("Minimum je {0}", ultra);
- Console.WriteLine("Průměr je {0}", prumer/10);
- Console.Read();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement