Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- class ReverseNumbers
- {
- static void Main()
- {
- int[] input = Console.ReadLine()
- .Split(new char[] { ' ' }, StringSplitOptions.RemoveEmptyEntries)
- .Select(int.Parse)
- .ToArray();
- var stack = new Stack<int>(input);
- Console.WriteLine(string.Join(" ", stack));
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment