Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- namespace TheBestPlayer
- {
- class Program
- {
- static void Main(string[] args)
- {
- //string[] names = { "OLeg", "Matviy", "Glib", "Mihaylo", "Petrys"};
- //int[] scores = { 30, 1000, 50000, 60, 70 };
- //int maxScore = 0;
- //int maxIndex = 0;
- //for (int i = 0; i < scores.Length; i++)
- //{
- // if (maxScore < scores[i])
- // {
- // maxIndex = i;
- // maxScore = scores[i];
- // }
- //}
- //Console.WriteLine(names[maxIndex] + " " + maxScore);
- int[] marks = { 1, 25, 6, 7, 4, 8 };
- int sumMarks = 0;
- for (int i = 0; i < marks.Length; i++)
- {
- sumMarks += marks[i];
- }
- Console.WriteLine(sumMarks);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement