Sortgame problem

please give me some hint how to take input both the name and the no. together.

Try to think of all the data structures you have studied, and which one would allow you to store values in pairs. Other than data structures, think if you know any way to create user defined data types that can be used for storing values in pairs. Think upon these hints, if you are not able to come up with anything, then let me know and I’ll help you out more.

till now their no as such any video , which has taught about taking input as pair , so if yu can help me in it

That’s okay. You should consider using a class or a hashmap for storing values in pairs. If you haven’t studied these topics, then you should watch the videos first and then attempt the question.

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.