stores the frequency of all single digit in three - digit number
freq = 10 * [ 0 ] NEW_LINE freq [ int ( dup % 10 ) ] += 1 ; NEW_LINE dup = dup / 10 NEW_LINE freq [ int ( dup % 10 ) ] += 1 ; NEW_LINE dup = dup / 10 NEW_LINE freq [ int ( dup % 10 ) ] += 1 ; NEW_LINE dup = i NEW_LINE