I need a coder in any of the skills

Job ID: 36808348

Budget: ₹600 – ₹1,500 INR

Stop the Shame (100 Marks)
The general public often body shame the people who are obese or not beautiful as per their standard of weight. They do not even consider that it might be a medical condition for some people. Because of this, the people start doubting themselves and start cutting them off from the general discussions or the public places. To fight body shaming and spread awareness about the issue, an event is conducted in the city where people are participating and are ranked according to their weights from highest to lowest. The people with the same weights are ranked the same.


There are N people who have already participated. The official has noted their weight and has ranked them. The problem is, he has fallen sick and there are still P people who are left to rank and participate. Considering this, you are expected to finish the process and provide the rank of the P people. Once the person is ranked, his weight is included in the category and the weight of the new person will have to consider this weight also to be ranked. To help you out, the new P people are organized in a queue in increasing order of their weights.