Buggy python submission (verdict: Time Limit Exceeded):
n,d = map(int,input().split())

xy = list()
d2 = d ** 2

for i in range(n):
    xy += map(int,input().split())

#xy_2 = int(len(xy) / 2)
#for i in range(xy_2):
#    x.append(xy.pop(0))
#    y.append(xy.pop(0))
xy2 = list()
for i in range(n):
    xy2.append(xy.pop(0)**2 + xy.pop(0)**2)
    
#xy2_2 = list(set(xy2))

#xy2.sort()

ans = 0
#ans += len(xy2) - len(xy2_2)
for i in xy2:
    if d2 >= i:
        ans += 1
#    else:
#        break

print(ans)




Fixed submission:
n,d = map(int,input().split())
d2 = d ** 2

xy2 = list()
for i in range(n):
    x,y = map(int,input().split())
    xy2.append(x**2+y**2)

    ans = 0
for i in xy2:
    if d2 >= i:
        ans += 1
print(ans)

Buggy python submission (verdict: Time Limit Exceeded):
n,d = map(int,input().split())

xy = list()
d2 = d ** 2

for i in range(n):
    xy += map(int,input().split())

#xy_2 = int(len(xy) / 2)
#for i in range(xy_2):
#    x.append(xy.pop(0))
#    y.append(xy.pop(0))
xy2 = list()
for i in range(n):
    xy2.append(xy.pop(0)**2 + xy.pop(0)**2)
    
#xy2_2 = list(set(xy2))

xy2.sort()

ans = 0
#ans += len(xy2) - len(xy2_2)
for i in xy2:
    if d2 >= i:
        ans += 1
#    else:
#        break

print(ans)




Fixed submission:
n,d = map(int,input().split())
d2 = d ** 2

xy2 = list()
for i in range(n):
    x,y = map(int,input().split())
    xy2.append(x**2+y**2)

    ans = 0
for i in xy2:
    if d2 >= i:
        ans += 1
print(ans)

Buggy python submission (verdict: Time Limit Exceeded):
import math
n,d = map(int,input().split())

y = list()
x = list()
xy = list()

for i in range(n):
    xy += map(int,input().split())

#xy_2 = int(len(xy) / 2)
#for i in range(xy_2):
#    x.append(xy.pop(0))
#    y.append(xy.pop(0))
xy2 = list()
for i in range(n):
    xy2.append(xy.pop(0)**2 + xy.pop(0)**2)
    

xy2.sort()

ans = 0
for i in range(n):
    if d >= math.sqrt(xy2[i]):
        ans += 1
    else:
        break

print(ans)



Fixed submission:
n,d = map(int,input().split())
d2 = d ** 2

xy2 = list()
for i in range(n):
    x,y = map(int,input().split())
    xy2.append(x**2+y**2)

    ans = 0
for i in xy2:
    if d2 >= i:
        ans += 1
print(ans)

Buggy python submission (verdict: Time Limit Exceeded):
import math
n,d = map(int,input().split())

y = list()
x = list()
xy = list()

for i in range(n):
    xy += map(int,input().split())

#xy_2 = int(len(xy) / 2)
#for i in range(xy_2):
#    x.append(xy.pop(0))
#    y.append(xy.pop(0))

ans = 0
for i in range(n):
    if d >= math.sqrt(xy.pop(0)**2 + xy.pop(0)**2):
        ans += 1

print(ans)

Fixed submission:
n,d = map(int,input().split())
d2 = d ** 2

xy2 = list()
for i in range(n):
    x,y = map(int,input().split())
    xy2.append(x**2+y**2)

    ans = 0
for i in xy2:
    if d2 >= i:
        ans += 1
print(ans)

Buggy python submission (verdict: Time Limit Exceeded):
import math
n,d = map(int,input().split())

y = list()
x = list()
xy = list()

for i in range(n):
    xy += map(int,input().split())

xy_2 = int(len(xy) / 2)
for i in range(xy_2):
    x.append(xy.pop(0))
    y.append(xy.pop(0))

ans = 0
for i in range(n):
    if d >= math.sqrt(x[i]**2 +y[i]**2):
        ans += 1

print(ans)

Fixed submission:
n,d = map(int,input().split())
d2 = d ** 2

xy2 = list()
for i in range(n):
    x,y = map(int,input().split())
    xy2.append(x**2+y**2)

    ans = 0
for i in xy2:
    if d2 >= i:
        ans += 1
print(ans)