Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Linq;
- using System.Collections.Generic;
- class Program
- {
- static void Main()
- {
- List<string> names = new List<string>();
- string command = string.Empty;
- while (true)
- {
- command = Console.ReadLine();
- if (command == "end")
- {
- break;
- }
- names.Add(command);
- }
- Console.WriteLine(string.Join(Environment.NewLine, names));
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement