Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- namespace _8.AppendArrays
- {
- class Program
- {
- static void Main(string[] args)
- {
- List<string> numbers = Console.ReadLine().Split('|').ToList();
- numbers.Reverse();
- numbers.RemoveAll(x => string.IsNullOrEmpty(x));
- string[] realNumbers = numbers.ToArray();
- Console.WriteLine(string.Join(" ", numbers), StringSplitOptions.RemoveEmptyEntries);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement