Problem Statment
An array arr[] of size N is given .
Find the first repeating element in an array of integers,i.e.,an element that occurs more than once and whose index of first occurrence is smallest.
Constraints:
1 <= N <= 10^6
0 <= A <= 10^6
Input Format
[1,2,3,4,3,1,6]
Output Format
element: 3
index: 2