Problem
Input format
The first line contains `n`. The next `n` lines each contain a name and a salary, separated by a space. - `1 <= n <= 300` - salaries are natural numbers between `1` and `100000` - the name has at most 30 characters and contains no spaces - use of `strcmp` and `strcpy` (from `<cstring>`) is permitted
Output format
Print `n` lines, each containing the name and salary of one employee, separated by a space, in the required order.
Example
4 Maria 3500 Ion 5000 Ana 2800 Vlad 5000
Ion 5000 Vlad 5000 Maria 3500 Ana 2800
Stuck?
Use the Get Hint button in the action bar to reveal a guided hint.
💬 Discussion
Loading...No comments yet. Be the first to start the discussion!
Sample cases (from the problem)
Sample Case 1
4 Maria 3500 Ion 5000 Ana 2800 Vlad 5000
Ion 5000 Vlad 5000 Maria 3500 Ana 2800
Solve it your way first
Community solutions unlock after you submit a passing solution. Don't peek.
Ready to solve this challenge?
Create a free account to write code, submit solutions, and track your progress.