Football Tournament
In the LKS football tournament, Mykyta, the physical education teacher, needs to compile the results and create the final standings. The tournament followed a single round-robin format, where each team played every other team exactly once. Teams earned 3 points for a win, 1 point for a draw, and 0 points for a loss. The standings also consider the goal difference, which is the difference between goals scored and goals conceded.
Teams should be ranked in descending order based on their points. If two or more teams have the same number of points, the team with the higher goal difference should be ranked higher.
Input
The first line contains a single integer N (1 < N < 1000000), representing the number of teams in the tournament. The second line lists N non-negative integers, indicating the points each team earned. The third line lists N integers, representing the goal difference for each team.
Output
Output N integers, representing the team numbers in the order they should appear in the final standings. If teams have the same points and goal difference, they should maintain their original order from the input.