NedyalkoKikov

DistinctNumbers

Jun 1st, 2016
85
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.46 KB | None | 0 0
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6.  
  7. namespace Distinct
  8. {
  9. class Distinct
  10. {
  11. static void Main()
  12. {
  13. int[] arr = Console.ReadLine().Split().Select(int.Parse).ToArray();
  14. int[] res = arr.Distinct().ToArray();
  15. foreach(int n in res)
  16. {
  17. Console.Write(", " + n);
  18. }
  19. }
  20. }
  21. }
Advertisement
Add Comment
Please, Sign In to add comment