using System;
using System.Linq;
public class Program
{
public static void Main()
int[] arr = { 1, 55,55, 2, 3, 77,77, 1, 3, 2, 2, 4,4 ,4, 4};
for (int i = 0; i < arr.Length; i++)
if (arr[i] == arr[i + 1])
Console.WriteLine(arr[i]);
return;
}