Find the repeating and the missing value with time complexity O(n)[With Python Code].
Problem Statement: Given an array arr[ ] of size N, each integer from the range [1, N] appears exactly once except A which appears twice and B which is missing. The task is to find the numbers A and B.
Examples:
Input: arr[ ] = {2, 1, 2}
Output: Mis...
Poulami Bakshi
Thanks for sharing!!!!