Problem
Ask
Submissions

Problem: Find All Numbers Disappeared in an Array

Medium
30 min
Understand how to find all missing integers in an array of size n with values in the range 1 to n. Learn to implement an efficient solution with linear time complexity and constant additional space, enhancing your problem-solving skills for coding interviews.

Statement

Given an array, nums, of nn integers where nums[i] is in the range [1,n][1, n], return an array of all the integers in the range [1,n][1, n] that doesn’t appear in nums.

Constraints:

  • n=n = nums.length

  • 1n1031 \leq n \leq 10^3

  • 11 \leq nums[i] n\leq n

Problem
Ask
Submissions

Problem: Find All Numbers Disappeared in an Array

Medium
30 min
Understand how to find all missing integers in an array of size n with values in the range 1 to n. Learn to implement an efficient solution with linear time complexity and constant additional space, enhancing your problem-solving skills for coding interviews.

Statement

Given an array, nums, of nn integers where nums[i] is in the range [1,n][1, n], return an array of all the integers in the range [1,n][1, n] that doesn’t appear in nums.

Constraints:

  • n=n = nums.length

  • 1n1031 \leq n \leq 10^3

  • 11 \leq nums[i] n\leq n