Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace SequencesOfStrings_4
- {
- class SequencesOfStrings_4
- {
- static void Main(string[] args)
- {
- string[] input = Console.ReadLine().Split();
- for (int i = 0; i < input.Length - 1; i++)
- {
- Console.Write(input[i]+" ");
- if (!input[i].Equals(input[i + 1]))
- {
- Console.WriteLine();
- }
- }
- Console.Write(input[input.Length-1]);
- Console.WriteLine();
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement