Find one excluded element from an Array

后端 未结 0 1894
星月不相逢
星月不相逢 2021-01-04 20:38

Suppose we have K elements numbered from 0 to K-1. An array called A with the size of n, contains at most K-1 of our elements. Find one excluded element in A in time of O(n)

相关标签:
回答
  • 消灭零回复
提交回复
热议问题