Job Sequencing Problem: You are given a set of N jobs where each job comes with a deadline and profit. The profit can only be earned upon completing the job within its deadline. Find the number of jobs done and the maximum profit that can be obtained. Each job takes a single unit of time and only one job can be performed at a time.
Round 4: Technical Interview
Find Kth Max occurring element in the Array.
Used HashMap and Heap to solve the question.
Time O(n*logn)
Find K-th Permutation Sequence: Given N and K, where N is the sequence of numbers from 1 to N([1,2,3….. N]) find the Kth permutation sequence.