CodeEff/ECCO huggingface dataset:
# Original solution
N = int(eval(input()))
sp = [list(input().split()) for i in range(N)]
for i in range(N):
  sp[i].append(i+1)
sorted_data = sorted(sp, key=lambda x:(x[0], -int(x[1])))
for i in range(N):
  print((sorted_data[i][2]))

# Optimized solution
N = int(eval(input()))
D = [list(map(str,input().split())) for _ in range(N)]
for i in range(N):
  D[i].append(i+1)
sorted_d = sorted(D, key = lambda x: (x[0], -int(x[1])))
for i in range(N):
  print((sorted_d[i][2]))
# Original solution

import math
import itertools
import statistics
#import collections

#n =  list(map(int, input().split()))
n = int(eval(input()))
data = []
for i in range(n):
    s, p = input().split()
    data.append((i+1, s, int(p)))

data.sort(key=lambda x:(x[1], -x[2]))

for i in range(n):
    print((data[i][0]))


# Optimized solution
n = int(eval(input()))
s = []
for i in range(n):
    x, y = list(input().split())
    s.append([x, int(y), i+1])

ans = sorted(s, key=lambda x: (x[0], -x[1]))
for x, y, a in ans:
    print(a)
# Original solution
n = int(eval(input()))
sp = [None]*n
for i in range(n):
    sp[i] = [input().split(" "), i+1]
sp = list([[[x[0][0], int(x[0][1])], x[1]] for x in sp])
sl = list([x[0][0] for x in sp])
sp2 = []
for s in sorted(list(set(sl))):
    l = list([x for x in sp if x[0][0] == s])
    sp2.extend(sorted(l, key=lambda x:x[0][1], reverse=True))
for x in sp2:
    print((x[1]))


# Optimized solution
n = int(eval(input()))
sp = [None]*n
for i in range(n):
    sp[i] = input().split(" ")
sp = list([[x[0], int(x[1])] for x in sp])
sl = list([x[0] for x in sp])
sp2 = []
for s in sorted(list(set(sl))):
    l = list([x for x in sp if x[0] == s])
    sp2.extend(sorted(l, key=lambda x:x[1], reverse=True))
for x in sp2:
    print((sp.index(x)+1))
# Original solution
n = int(eval(input()))

d1 = dict()

for i in range(n):
	s, p = [x for x in input().split()]
	if (s not in list(d1.keys())):
		d1[s] = []
		d1[s].append((int(p), i + 1))
	else:
		d1[s].append((int(p), i + 1))

for v in list(d1.values()):
	v.sort(reverse = True)

l1 = list()

for k, v in list(d1.items()):
		l1.append((k, v))

l1.sort()

for i in range(len(l1)):
	for j in l1[i][1]:
		print((j[1]))

# Optimized solution
from sys import stdin, stdout

n = int(stdin.readline().rstrip())

l = list()

for i in range(n):
    s, p = [x for x in stdin.readline().rstrip().split()]
    l.append((s, int(p)*(-1), i + 1))
    
l.sort()
    
for i in range(n):
    print((l[i][2]))
# Original solution
import sys
sys.setrecursionlimit(10 ** 5)


def LI(): return [int(x) for x in sys.stdin.readline().split()]


def LI_(): return [int(x) - 1 for x in sys.stdin.readline().split()]


def LF(): return [float(x) for x in sys.stdin.readline().split()]


def LS(): return sys.stdin.readline().split()


def II(): return int(sys.stdin.readline())


def SI(): return eval(input())


N = int(eval(input()))
X = {}
for i in range(1, N+1):
    s, p = input().split()
    if s in X:
        X[s] += [(int(p), i)]
    else:
        X[s] = [(int(p), i)]

X = sorted(X.items())
for v in X:
    a = sorted(v[1], reverse=True)
    for i in a:
        print((i[1]))


# Optimized solution
N = int(eval(input()))
A = []
for i in range(1,N+1):
  c, s = input().split()
  s = 100 - int(s)
  A.append((c, s, i))
  
A.sort()
for a in A:
  print((a[2]))
# Original solution
rests = {}
for i in range(int(eval(input()))):
    S,P = input().split()
    P = int(P)
    if S in rests:
        rests[S] += [[P,i]]
    else:
        rests[S] = [[P,i]]
        
r = sorted(rests.items()) #市の名前でソート
for city in r:
    city[1].sort()
    city[1].reverse()
    
    for score,i in city[1]:
        print((i+1))
       

# Optimized solution
lst = []
for i in range(int(eval(input()))):
    S,P = input().split()
    lst.append([S,int(P),i+1])
lst2 = sorted(lst, key=lambda x:x[1],reverse=True)
lst3 = sorted(lst2, key=lambda x:x[0],reverse=False)
for i in lst3:
    print((i[2]))
# Original solution
n = int(eval(input()))
SP = []
for i in range(n):
    s, p = input().split()
    SP += [[s,int(p),i+1]]
SP.sort(key=lambda A:(A[0],-A[1]))
for sp in SP:
	print((sp[2]))

# Optimized solution
N = int(eval(input()))

SP = []
for i in range(N):
  s,p = input().split()
  SP.append((s,-int(p),i+1))
  
SP.sort()

for s,p,i in SP:
  print(i)
# Original solution
from operator import itemgetter

N = int(eval(input()))

SP = [input().split() for i in range(N)]

for k, v in enumerate(SP):
    v.insert(0, str(k + 1))
    v[2] = int(v[2])

# 降順
SP.sort(key=itemgetter(2), reverse=True)

# 昇順
SP.sort(key=itemgetter(1))

for sp in SP:
    print((sp[0]))


# Optimized solution
N = int(eval(input()))

SP = {i+1: input().split() for i in range(N)}

for v in list(SP.values()):
    v[1] = int(v[1])

# 降順
SP = sorted(list(SP.items()), key=lambda x: x[1][1], reverse=True)

# 昇順
SP = sorted(SP, key=lambda x: x[1][0])

for sp in SP:
    print((sp[0]))
# Original solution
import copy

n = int(eval(input()))
l = [input().split() for i in range(n)]
index = copy.deepcopy(l)

for i in range(n):
    l[i][1] = int(l[i][1])
    index[i][1] = int(index[i][1])

l.sort(key=lambda x: x[1], reverse=True)
l.sort(key=lambda x: x[0], reverse=False)

for i in range(n):
    for j in range(n):
        if l[i] == index[j]:
            print((j+1))
            break


# Optimized solution
import copy

res_list = []
n = int(eval(input()))
for i in range(n):
    name, score = input().split()
    score = int(score)

    res_list.append([name,score,i+1])

res_list.sort(key=lambda x: x[1],reverse=True)
res_list.sort(key=lambda x: x[0],reverse=False)

for i in res_list:
    print((i[2]))
# Original solution
n = int(eval(input()))
sp = [input().split() for _ in range(n)]
for i in sorted(list(range(n)), key=lambda i: (sp[i][0], -int(sp[i][1]))):
    print((i + 1))

# Optimized solution
n = int(eval(input()))
sp = [input().split() for _ in range(n)]
for (s, p), i in sorted(zip(sp, list(range(1, n + 1))), key=lambda x: (x[0][0], -int(x[0][1]))):
    print(i)
# Original solution
from operator import itemgetter
N=int(eval(input()))
listA=[[] for i in range(N)]
listANS=[]
for i in range(N):
  S,P=input().split()
  listA[i]+=[S,int(P),i+1]
listA.sort()
before=0
if N!=1:
  for i in range(1,N):
    if listA[i-1][0]!=listA[i][0]:
      listN=listA[before:i]
      listN.sort(key=itemgetter(1),reverse=True)
      listANS+=listN
      before=i
 
    if i==N-1:
      listN=listA[before:N]
      listN.sort(key=itemgetter(1),reverse=True)
      listANS+=listN
else:
  listANS=listA
for i in range(N):
  print((listANS[i][2]))

# Optimized solution
N = int(eval(input()))
a = [input().split() +[i+1] for i in range(N)]
a = sorted(a ,key=lambda x:(x[0], -int(x[1])))
 
for i in range(N):
  print((a[i][2]))
# Original solution
N = int(eval(input()))

ss = dict()
sss = dict()
for i in range(N):
    s, p = input().split()
    sss[s, p] = i + 1
    if s in ss:
        ss[s] = ss[s] + ',' + p
    else:
        ss[s] = p

ss_sorted = sorted(ss.items())

for tmp_ss in ss_sorted:
    s = tmp_ss[0]
    ps = list(map(int, tmp_ss[1].split(',')))
    ps.sort(reverse=True)
    for p in ps:
        print((sss[s, str(p)]))

# Optimized solution
N = int(eval(input()))


ss = list()
for i in range(N):
    s, p = input().split()
    ss.append([s, int(p), i])

ss_sorted = sorted(ss, key=lambda x: (x[0], -x[1]))

for out in ss_sorted:
    print((out[2] + 1))
# Original solution
n = int(eval(input()))
a = []
for i in range(1,n+1):
    s, p  = input().split()
    p = int(p)
    a.append((s, -p, i))

a.sort()
for s, p, i in a:
    print(i)



# Optimized solution
n = int(eval(input()))
a = []
for i in range(1,n+1):
    s, p = input().split()
    a.append((s, -1*int(p), i))

a.sort()
for i in a:
    print((i[2]))
# Original solution
n=int(eval(input()))
List=[]
for i in range(n):
    s,p=input().split()
    p=int(p)
    List.append([s,p,i+1])
List.sort()
S=List[0][0]
k=[]
for i in List:
    if i[0]==S:
        k.append([i[1],i[2]])
    else:
        k.sort(reverse=True)
        for j in k:
            print((j[1]))
        S=i[0]
        k=[]
        k.append([i[1],i[2]])
k.sort(reverse=True)
for j in k:
    print((j[1]))


# Optimized solution
n=int(eval(input()))
List=[]
for i in range(n):
    s,p=input().split()
    p=-int(p)
    List.append([s,p,i+1])
List.sort()
for i in List:
    print((i[2]))
# Original solution
import math
import copy

class Score:
    def set_data(self, town, score, idx):
        self.town = set_town
        self.score = set_score
        self.idx = set_idx

inputa = input().split()
# inputb = input().split()

a = int(inputa[0])
# b = int(inputa[1])
# c = int(inputa[2])

# x = int(inputb[0])
# y = int(inputb[1])

# inputList=[]
# for i in range(a):
#     inputNum = input()
#     inputList.append(inputNum)

inputList=[]
for i in range(a):
    inputItem = input().split()
    inputItem.append(i+1)
    inputList.append(inputItem)


# listb = []
# listb = [int(n) for n in inputb]

inputNameListSorted = []
tmp = sorted(inputList, key=lambda x:int(x[1]), reverse = True)
inputNameListSorted = sorted(tmp, key=lambda x:x[0])

for i in range(len(inputNameListSorted)):
    print((inputNameListSorted[i][2]))

# Optimized solution
import sys

# import math
# import bisect

# import copy
# import heapq
# from collections import deque
# import decimal

# sys.setrecursionlimit(100001)
# INF = sys.maxsize
# MOD = 10 ** 9 + 7

ni = lambda: int(sys.stdin.readline())
ns = lambda: list(map(int, sys.stdin.readline().split()))
na = lambda: list(map(int, sys.stdin.readline().split()))


# ===CODE===


def main():
    n = ni()
    d = []
    for i in range(n):
        s, p = input().split()
        d.append((s, int(p), i + 1))

    tmp = sorted(d, key=lambda x: x[1], reverse=True)
    tmp1 = sorted(tmp, key=lambda x: x[0])

    for t in tmp1:
        print((t[2]))


if __name__ == '__main__':
    main()
# Original solution
n=int(eval(input()))
ls=[]
for i in range(1,n+1):
    s,p=input().split()
    ls.append([s,int(p),i])
ls.sort(key=lambda x: (x[0],-x[1]))
for i in range(len(ls)):
    print((ls[i][2]))
##

# Optimized solution
n=int(eval(input()))
ans=[]
for i in range(n):
    s,p=input().split()
    ans.append([s,p,i+1])
ans.sort(key=lambda x:(x[0],-int(x[1])))
for i in range(n):
    print((ans[i][2]))
# Original solution
N = int(eval(input()))
rests = {}
cities = []
lst = []

for i in range(N):
    S, P = input().split()
    cities.append(S)
    lst.append((S, int(P)))
    try:
        rests[S].append(int(P))
        rests[S].sort()
    except KeyError:
        rests[S] = [int(P)]

cities.sort()
order = [(city, rests[city].pop()) for city in cities]

for rest in order:
    print((lst.index(rest) + 1))

# Optimized solution
N = int(eval(input()))
rests = []

for i in range(1, N+1):
    S, P = input().split()
    rests.append((S, int(P), i))

rests.sort(key=lambda x: x[0]+chr(100-x[1]))
for rest in rests:
    print((rest[2]))
# Original solution
import operator
n = int(eval(input()))
s = []
p = []
for i in range(n):
    x, y = input().split()
    s.append((x, int(y), i+1))
s = sorted(s, key=lambda x:(x[0], -x[1]))
for c in s:
    print((c[2]))

# Optimized solution
N = int(eval(input()))
points = []
for i in range(N):
    city, point = input().split()
    points.append((city, -int(point), i+1))
points.sort(key=lambda x:(x[0],x[1]))
for xs in points:
    print((xs[2]))
# Original solution
n=int(eval(input()))
lists=[]
for x in range(n):
  a,b=input().split()
  lists.append([a,int(b),x+1])
lists.sort(key=lambda t:t[1],reverse=True)
lists.sort(key=lambda t:t[0])
for x in range(n):
  print((lists[x][2]))

# Optimized solution
n=int(eval(input()))
l=[]
for i in range(n):
  s,p=input().split()
  l.append([i+1,s,int(p)])
l.sort(key=lambda x:x[2],reverse=True)
l.sort(key=lambda x:x[1])
for ll in l:
  print((ll[0]))
# Original solution
n=int(eval(input()))
gr=[]
for i in range(n):
  s,p=input().split()
  p=int(p)
  gr.append([[s,p],i])

gr=sorted(gr,key=lambda x:(x[0][0],-x[0][1]))

for i in range(len(gr)):
  print((gr[i][1]+1))

# Optimized solution
N=int(eval(input()))
data = [None] * N
for i in range(N):
  data[i] = list(input().split()) + [i+1]
  
data = sorted(data,key=lambda x:(x[0],-int(x[1])))
for d in data:
  print((d[2]))
# Original solution
N = int(eval(input()))
l = []
for i in range(N):
    s,p = input().split(" ")
    l.append([s,-int(p),i+1])
l.sort()

for s,p,i in l:
    print(i)

# Optimized solution
N = int(eval(input()))
l = []
for i in range(N):
    s,p = input().split(" ")
    l.append([s,-int(p),i+1])
l.sort()

for i in l:
    print((i[2]))
# Original solution
a = int(eval(input()))
l = [list(input().split()) for i in range(a)]
b = sorted(l, key=lambda x:(x[0], -int(x[1])))
for i in b:
  for k, j in enumerate(l, 1):
    if j == i:
      print(k)

# Optimized solution
n = int(eval(input()))
sp = []
for i in range(n):
  s, p = input().split()
  sp.append([s, int(p), i+1])
sp.sort(key=lambda sp:(sp[0],-sp[1]))
for i in sp:
  print((i[2]))
# Original solution

def comp_rest(a,b):
    if a[0] > b[0]:
        return True
    elif a[0] < b[0]:
        return False
    elif a[0] == b[0]:
        return a[1] < b[1]

def solve():
    N = int(input())
    SP = []
    for i in range(N):
        SiPi = input().split()
        Si = SiPi[0]
        Pi = int(SiPi[1])
        SP.append([Si, Pi, i+1])
    for i in range(N):
        for j in range(i+1, N):
            if comp_rest(SP[i], SP[j]):
                SP[i], SP[j] = SP[j], SP[i]
    for i in range(N):
        print(SP[i][2])

if __name__ == '__main__':
    solve()


# Optimized solution
def solve():
    N = int(input())
    SP = []
    for i in range(N):
        SiPi = input().split()
        Si = SiPi[0]
        Pi = int(SiPi[1])
        SP.append([Si, - Pi, i+1])
    SP.sort()
    for i in range(N):
        print(SP[i][2])

if __name__ == '__main__':
    solve()
# Original solution
import sys
from collections import defaultdict

read = sys.stdin.read
readline = sys.stdin.readline
readlines = sys.stdin.readlines
sys.setrecursionlimit(10 ** 9)
INF = 1 << 60


def main():
    N = int(readline())
    d = defaultdict(list)
    for i in range(N):
        s, p = readline().strip().split()
        p = int(p)
        d[s].append((p, i+1))

    for city, points in sorted(d.items()):
        points = sorted(points, reverse=True)
        for _, i in points:
            print(i)

    return


if __name__ == '__main__':
    main()


# Optimized solution
import sys
from operator import itemgetter

read = sys.stdin.read
readline = sys.stdin.readline
readlines = sys.stdin.readlines
sys.setrecursionlimit(10 ** 9)
INF = 1 << 60


def main():
    N = int(readline())
    A = [0] * N
    for i in range(N):
        s, p = readline().strip().split()
        p = int(p)
        A[i] = (s, p, i + 1)

    A.sort(key=itemgetter(1), reverse=True)
    A.sort(key=itemgetter(0))
    for s, p, i in A:
        print(i)

    return


if __name__ == '__main__':
    main()
# Original solution
print(('\n'.join([l[2] for l in sorted(sorted([[l[0], -int(l[1]), str(l[2] + 1)] for l in (input().split() + [i] for i in range(int(eval(input()))))], key=lambda x: x[1]), key=lambda x: x[0])])))

# Optimized solution
print(*[s[2] for s in sorted([input().split() + [i + 1] for i in range(int(input()))],key=lambda x:(x[0], -int(x[1])))],sep='\n')
# Original solution
#Fukushimaken: 
from heapq import heappop, heappush
OUT, IN = 0, 1
def P(i):
    return 31 if i % 5 == 1 else 3

def M(i):
    return 17 * (i % 2) + 3 * (i % 3) + 19

def check(c, n):
    for i in range(16):
        if (c >> i) & n == 0:
            return i
    return None

ans = [-1] * 100 + [0]
eq = [(i * 5, i, IN, None, P(i)) for i in range(100)]
c = 1 << 17
while len(eq) != 0:    
    m, n, et, i, p = heappop(eq)
    if et == IN:        
        i = check(c, p)
        if ans[n-1] != -1 and i is not None:
            c = c | (p << i)
            ans[n] = m - n * 5
            heappush(eq, (m + M(n), n, OUT, i, p))
        else:
            heappush(eq, (m + 1, n, IN, None, p)) #
    else:        
        c = c ^ (p << i)

while True:
    try:
        n = eval(input())
        print(ans[n])
    except:
        break

# Optimized solution
#Fukushimaken: 
from heapq import heappop, heappush
def P(i):
    return 31 if i % 5 == 1 else 3

def M(i):
    return 17 * (i % 2) + 3 * (i % 3) + 19

def check(c, n):
    for i in range(16):
        if (c >> i) & n == 0:
            return i
    return None

ans = [-1] * 100 + [0]
eq = [(i * 5, i, None, P(i)) for i in range(100)]
c = 1 << 17
while len(eq) != 0:    
    m, n, i, p = heappop(eq)
    if i is None:        
        i = check(c, p)
        if ans[n-1] != -1 and i is not None:
            c = c | (p << i)
            ans[n] = m - n * 5
            heappush(eq, (m + M(n), n, i, p))
        else:
            heappush(eq, (m + 1, n, None, p)) #
    else:        
        c = c ^ (p << i)

while True:
    try:
        print(ans[eval(input())])
    except:
        break
# Original solution
n,x,y=list(map(int,input().split()))
x-=1
y-=1
a=[]
for i in range(n):
  a.append(0)
for i in range(n):
  for j in range(n):
    if i<j:
      p=min(abs(j-i),abs(x-i)+abs(y-j)+1,abs(y-i)+abs(x-j)+1)
      a[p]+=1
for i in range(n-1):
  print((str(a[i+1])))

# Optimized solution
n,x,y=list(map(int,input().split()))
x-=1
y-=1
a=[]
for i in range(n):
  a.append(0)
for i in range(n-1):
  for j in range(n-i):
    j=n-1-j
    p=min(abs(j-i),abs(x-i)+abs(y-j)+1,abs(y-i)+abs(x-j)+1)
    a[p]+=1
for i in range(n-1):
  print((str(a[i+1])))
# Original solution
N, X, Y = map(int, input().split())
X = X-1
Y = Y-1

cnt = [0]*N
for i in range(N):
    for j in range(N):
        if j >= i:
            continue
        dist = min(abs(i-j),
                   abs(X-i) + abs(Y-j) + 1,
                   abs(X-j) + abs(Y-i) + 1)
        cnt[dist] += 1

print(*cnt[1:], sep='\n')


# Optimized solution
N, X, Y = map(int, input().split())
X = X-1
Y = Y-1

cnt = [0]*N
for i in range(N):
    for j in range(i+1, N):
        dist = min(abs(i-j),
                   abs(X-i) + abs(Y-j) + 1,
                   abs(X-j) + abs(Y-i) + 1)
        cnt[dist] += 1

print(*cnt[1:], sep='\n')
# Original solution
import sys
input = sys.stdin.readline
import collections

N, X, Y = list(map(int, input().split()))

def bfs(i, j):
    dist = [-1]*N
    dist[i] = 0
    que = collections.deque([])
    que.append(i)
    
    while len(que) != 0:
        v = que.popleft()
        for nv in graph[v]:
            if dist[nv] != -1:continue
            dist[nv] = dist[v]+1
            if nv == j:break
            que.append(nv)
    return dist[j]

graph = {}
for i in range(N):
    graph[i] = set()

for i in range(N-1):
    graph[i].add(i+1)
    graph[i+1].add(i)
graph[X-1].add(Y-1)
graph[Y-1].add(X-1)

ans = [0]*N
for i in range(N):
    for j in range(i+1,N):
        d = bfs(i,j)
        ans[d] += 1
for i in range(N):
    if i == 0:continue
    print((ans[i]))

# Optimized solution
import sys
input = sys.stdin.readline
import collections

N, X, Y = list(map(int, input().split()))

def bfs(i):
    dist = [-1]*N
    dist[i] = 0
    que = collections.deque([])
    que.append(i)
    
    while len(que) != 0:
        v = que.popleft()
        for nv in graph[v]:
            if dist[nv] != -1:continue
            dist[nv] = dist[v]+1
            que.append(nv)
    return dist[i+1:]

graph = {}
for i in range(N):
    graph[i] = set()

for i in range(N-1):
    graph[i].add(i+1)
    graph[i+1].add(i)
graph[X-1].add(Y-1)
graph[Y-1].add(X-1)

d = collections.Counter([])
for i in range(N):
    d += collections.Counter(bfs(i))
for i in range(1,N):
    if i == N-1:
        print((0))
    else:
        print((d[i]))
# Original solution
import sys
input = sys.stdin.readline
import collections

N, X, Y = list(map(int, input().split()))

def bfs(i):
    dist = [-1]*N
    dist[i] = 0
    que = collections.deque([])
    que.append(i)
    
    while len(que) != 0:
        v = que.popleft()
        for nv in graph[v]:
            if dist[nv] != -1:continue
            dist[nv] = dist[v]+1
            que.append(nv)
    return dist[i+1:]

graph = {}
for i in range(N):
    graph[i] = set()

for i in range(N-1):
    graph[i].add(i+1)
    graph[i+1].add(i)
graph[X-1].add(Y-1)
graph[Y-1].add(X-1)

d = collections.Counter([])
for i in range(N):
    d += collections.Counter(bfs(i))
for i in range(1,N):
    if i == N-1:
        print((0))
    else:
        print((d[i]))

# Optimized solution
import sys
input = sys.stdin.readline
from collections import deque
from collections import Counter
def main():
    N, X, Y = list(map(int, input().split()))
    graph = {}
    for i in range(N):
        graph[i] = set()
    for i in range(N-1):
        graph[i].add(i+1)
        graph[i+1].add(i)
    graph[X-1].add(Y-1)
    graph[Y-1].add(X-1)

    ans = []
    for i in range(N):
        dist = [-1] * N
        dist[i] = 0
        que = deque([])
        que.append(i)
        while len(que) != 0:
            v = que.popleft()
            for nv in graph[v]:
                if dist[nv] != -1:continue
                dist[nv] = dist[v] + 1
                que.append(nv)
        ans += dist
    ans = Counter(ans)
    for i in range(1, N):
        print((ans[i]//2))
if __name__ == "__main__":
    main()
# Original solution
def main():
    N, X, Y = list(map(int, input().split()))
    X -= 1
    Y -= 1

    print(N)
    for k in range(2, N):
        ans = 0
        for i in range(N):
            ans += sum(1 for j in range(i + 1, N)
                       if min(j - i, abs(i - X) + abs(j - Y) + 1) == k)
        print(ans)


main()


# Optimized solution
def main():
    N, X, Y = list(map(int, input().split()))
    X -= 1
    Y -= 1

    print(N)
    dist = [0] * (N + 1)

    for i in range(N):
        for j in range(i + 1, N):
            d = min(j - i, abs(i - X) + abs(j - Y) + 1)
            dist[d] += 1

    for k in range(2, N):
        print((dist[k]))


main()
# Original solution
from itertools import combinations
from collections import defaultdict
inf=10**7
n,x,y=list(map(int,input().split()))
x-=1
y-=1
dis={}
cnt=defaultdict(int)
for i,j in combinations(list(range(n)),2):
  dis[(i,j)]=min(abs(j-i),abs(j-y)+1+abs(i-x),abs(j-x)+1+abs(i-y))
for i,j in combinations(list(range(n)),2):
  cnt[dis[(i,j)]]+=1
for k in range(1,n):
  print((cnt[k]))

# Optimized solution
from itertools import combinations
from collections import defaultdict
n,x,y=list(map(int,input().split()))
x-=1
y-=1
cnt=defaultdict(int)
for i,j in combinations(list(range(n)),2):
  cnt[min(abs(j-i),abs(j-y)+1+abs(i-x),abs(j-x)+1+abs(i-y))]+=1
for k in range(1,n):
  print((cnt[k]))
# Original solution
def main():
  N,X,Y = list(map(int,input().split()))
  d = [[float('inf') for _ in range(N)] for _ in range(N)]
  for i in range(N-1):
    d[i][i+1] = 1
    d[i+1][i] = 1
  d[X-1][Y-1] = 1
  d[Y-1][X-1] = 1
  for i in range(N):
    d[i][i] = 0
  
  for k in range(N):
    for i in range(N):
      for j in range(N):
        d[i][j] = min(d[i][k]+d[k][j],d[i][j])
  #print(d)
  ans = [0 for _ in range(N-1)]
  for i in range(N-1):
    for j in range(i,N):
      if 0 < d[i][j] < N:
        ans[d[i][j]-1] += 1
  for i in range(N-1):
    print((ans[i]))

main()

# Optimized solution
def main():
  N,X,Y = list(map(int,input().split()))
  V = [[] for _ in range(N)]
  
  for i in range(N-1):
    V[i].append(i+1)
    V[i+1].append(i)
  X -= 1
  Y -= 1
  V[X].append(Y)
  V[Y].append(X)
  #print(V)
  
  ans = [0 for _ in range(N)]
  INF = float('INF')
  for s in range(N):
    D = [INF for _ in range(N)]
    q = [s]
    d = 0
    while(q):
      q2 = []
      for v in q:
        D[v] = min(D[v],d)
        for u in V[v]:
          if D[u] == INF:
            q2.append(u)
      q = q2[:]
      d += 1
      #print(q,d,D)
    for i in range(N):
      ans[D[i]] += 1
  for i in range(1,N):
    print((ans[i]//2))

main()