you give sorted array consist integer element appear exactly twice element appear exactly oncereturn single element appear onceyour solution run Olog n time o1 space Example 1input num 112334488output 2Example 2input num 3377101111output 10 Constraints1 numslength 1050 numsi 105