Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- /* Написать метод, который возвращает
- * наибольший элемент в массиве*/
- namespace ConsoleApp4
- {
- class Program
- {
- static void Main(string[] args)
- {
- Console.WriteLine(Method(1,2,6,3,5));
- }
- static int Method(params int[] array)
- {
- int maxValue = array.Max<int>();
- return maxValue;
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement