Data Structures · frontend · javascript · technology

#Javascript Array- find missing integers

Problem statement: You have a list of You’re given an array of N integers. N may be very large. You know that every integer appears once in the array, except there is one or more integer(s) missing. Condition 1: When all the integers in the array is positive: consider this array : [0, 1, 3,… Continue reading #Javascript Array- find missing integers

Data Structures · frontend · javascript

#Javascript Array – Find missing number in array

The problem statement is to find missing number in an consecutive array of numbers. First find sum of N consecutive number can be found by N* (N+1) /2 . second step is to find sum of all the number in an array, we can use any loopbut suggestion is to use Array.reduce(); Lets look at… Continue reading #Javascript Array – Find missing number in array