Buggy python submission (verdict: Time Limit Exceeded):
from collections import Counter
import itertools

def warshall_floyd(d):
    #d[i][j]: iからjへの最短距離
    for k in range(n):
        for i in range(n):
            for j in range(n):
                d[i][j] = min(d[i][j],d[i][k] + d[k][j])
    return d

n, x, y = map(int, input().split())
d = [[n]*n for i 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
warshall_floyd(d)
D = Counter(list(itertools.chain.from_iterable(d)))
for i in range(1, n):
    print(D[i]//2)

Fixed submission:
import collections
n, x, y = map(int, input().split())
d = [[0]*(i+1) for i in range(n)]
x -= 1
y -= 1
for i in range(n):
    for j in range(i+1):
        d[i][j] = min(i-j, abs(x-j)+abs(y-i)+1)
L = []
for i in range(n):
    for dd in d[i]:
        L.append(dd)
C = collections.Counter(L)
for i in range(1, n):
    print(C[i])

Buggy python submission (verdict: Time Limit Exceeded):
from collections import Counter
import itertools

def warshall_floyd(d):
    #d[i][j]: iからjへの最短距離
    for k in range(n):
        for i in range(n):
            for j in range(n):
                d[i][j] = min(d[i][j],d[i][k] + d[k][j])
    return d

n, x, y = map(int, input().split())
d = [[float("inf")]*n for i 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
warshall_floyd(d)
D = Counter(list(itertools.chain.from_iterable(d)))
for i in range(1, n):
    print(D[i]//2)

Fixed submission:
import collections
n, x, y = map(int, input().split())
d = [[0]*(i+1) for i in range(n)]
x -= 1
y -= 1
for i in range(n):
    for j in range(i+1):
        d[i][j] = min(i-j, abs(x-j)+abs(y-i)+1)
L = []
for i in range(n):
    for dd in d[i]:
        L.append(dd)
C = collections.Counter(L)
for i in range(1, n):
    print(C[i])

Buggy python submission (verdict: Time Limit Exceeded):
from collections import Counter
def warshall_floyd(d):
    #d[i][j]: iからjへの最短距離
    for k in range(n):
        for i in range(n):
            for j in range(n):
                d[i][j] = min(d[i][j],d[i][k] + d[k][j])
    return d

n, x, y = map(int, input().split())
d = [[float("inf")]*n for i 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
warshall_floyd(d)

L = [0] * (n**2)
for i in range(n):
    for j in range(n):
        L[n*i+j] = d[i][j]
D = Counter(L)
for i in range(1, n):
    print(D[i]//2)

Fixed submission:
import collections
n, x, y = map(int, input().split())
d = [[0]*(i+1) for i in range(n)]
x -= 1
y -= 1
for i in range(n):
    for j in range(i+1):
        d[i][j] = min(i-j, abs(x-j)+abs(y-i)+1)
L = []
for i in range(n):
    for dd in d[i]:
        L.append(dd)
C = collections.Counter(L)
for i in range(1, n):
    print(C[i])

Buggy python submission (verdict: Time Limit Exceeded):
from collections import Counter
def warshall_floyd(d):
    #d[i][j]: iからjへの最短距離
    for k in range(n):
        for i in range(n):
            for j in range(n):
                d[i][j] = min(d[i][j],d[i][k] + d[k][j])
    return d

n, x, y = map(int, input().split())
d = [[float("inf")]*n for i 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
warshall_floyd(d)

L = [0] * (n**2)
for i in range(n):
    for j in range(n):
        L[n*i+j] = d[i][j]
D = Counter(L)
for i in range(1, n):
    print(D[i]//2)

Fixed submission:
import collections
n, x, y = map(int, input().split())
d = [[0]*(i+1) for i in range(n)]
x -= 1
y -= 1
for i in range(n):
    for j in range(i+1):
        d[i][j] = min(i-j, abs(x-j)+abs(y-i)+1)
L = []
for i in range(n):
    for dd in d[i]:
        L.append(dd)
C = collections.Counter(L)
for i in range(1, n):
    print(C[i])