Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- namespace Largest3Numbers
- {
- class MainClass
- {
- public static void Main()
- {
- List<int> numbers = Console.ReadLine().Split().Select(int.Parse).ToList();
- var filteredList = numbers.OrderByDescending(x => x).ToList();
- Console.WriteLine(string.Join(" ",filteredList.Take(3)));
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement