Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Text.RegularExpressions;
- namespace Advanced
- {
- class Program
- {
- static void Main(string[] args)
- {
- var periodicTable = new SortedSet<string>();
- int number = int.Parse(Console.ReadLine());
- for (int i = 0; i < number; i++)
- {
- var elements = Console.ReadLine().Split();
- foreach (var element in elements)
- {
- periodicTable.Add(element);
- }
- }
- Console.WriteLine(string.Join(" ", periodicTable));
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment