find the mssing no by js code example
Example: find the missing value in an integer array javascript
let a = [5, 7],
count = 10,
missing = []
for (let i = 1; i <= count; i++) {
if (a.indexOf(i) === -1) {
missing.push(i)
}
}
console.log(missing)