Company: Kotak_17oct
Difficulty: medium
Donation Problem Description There are 10 9 empty handed people standing in a line. You have to perform Q independent queries and you have been given an integer K . Each query is of type: L R Y: Donate Y coin to each person standing at position X such that L ≤ X and X ≤ R . After performing the given Q queries, print the positions (one-based index) of the first K people having a prime number of coins. Function Description Complete the function K_Prime . This function takes the following 3 parameters and returns the required answer: Q: Represents the number of queries. queries: Represent the container containing all the queries. K: Represents the number of people that need to be printed. Input Format for Custom Testing Note: Use this input format if you are testing against custom input or writing code in a language where we don't provide boilerplate code. The first line contains T , which represents the number of test cases. For each test case: The first line contains an integer Q