Computer Science, asked by lucy38491, 1 year ago

K-th missing element in an unsorted array. Given an unsorted sequence a[], the task is to find the k-th missing contiguous element in the increasing sequence of the array elements i.E. Consider the array in sorted order and find the kth missing number. If no k-th missing element is there output -1.

Answers

Answered by bhuvana8265
0

Answer:

bro I don't know who u r but the is computer science but the question is chemistry

Answered by ishikaij
0

Answer:first sort the given array than start a loop from the a[0] and compare elemnts if present in array by position. Make count of missing element and print k th missing element.

Best approach use unordered set in c++.

Explanation:

Similar questions