Buggy python submission (verdict: Runtime Error):
import math
n,*x=map(int,open(0).read().split())
x.sort()
a=[i-j for i,j in zip(x[1:],x[:-1])]
set(a)
a.sort()
b=[i for i in a if i%a[0]]
b.append(a[0])
if len(b)==1:
    print(*b)
else:
    ans=b[0]
    for i in b[1:]:
        ans=math.gcd(ans,i)
    print(ans) 

Fixed submission:
import fractions
n,*x=map(int,open(0).read().split())
x.sort()
a=[i-j for i,j in zip(x[1:],x[:-1])]
set(a)
a.sort()
b=[i for i in a if i%a[0]]
b.append(a[0])
if len(b)==1:
    print(*b)
else:
    ans=b[0]
    for i in b[1:]:
        ans=fractions.gcd(ans,i)
    print(ans)

Buggy python submission (verdict: Runtime Error):
import math
n,s,*x=map(int,open(0).read().split())
a=[abs(i-s) for i in x]
set(a)
ans=min(a)
for i in a:
    if i%ans==0:
        continue
    else:
        ans=math.gcd(ans,ans%i)
print(ans)  

Fixed submission:
import fractions
n,*x=map(int,open(0).read().split())
x.sort()
a=[i-j for i,j in zip(x[1:],x[:-1])]
set(a)
a.sort()
b=[i for i in a if i%a[0]]
b.append(a[0])
if len(b)==1:
    print(*b)
else:
    ans=b[0]
    for i in b[1:]:
        ans=fractions.gcd(ans,i)
    print(ans)

Buggy python submission (verdict: Runtime Error):
import math
n,s,*x=map(int,open(0).read().split())
a=[abs(i-s) for i in x]
set(a)
ans=a[0]
for i in a[1:]:
    if i%ans==0:
        continue
    else:
        ans=math.gcd(ans,i)
print(ans)   

Fixed submission:
import fractions
n,*x=map(int,open(0).read().split())
x.sort()
a=[i-j for i,j in zip(x[1:],x[:-1])]
set(a)
a.sort()
b=[i for i in a if i%a[0]]
b.append(a[0])
if len(b)==1:
    print(*b)
else:
    ans=b[0]
    for i in b[1:]:
        ans=fractions.gcd(ans,i)
    print(ans)

Buggy python submission (verdict: Runtime Error):
import math
n,*x=map(int,open(0).read().split())
x.sort()
a=[i-j for i,j in zip(x[1:],x[:-1])]
set(a)
a.sort()
b=[i for i in a if i%a[0]]
b.append(a[0])
if len(b)==1:
    print(*b)
else:
    print(gcd(b[0],b[1]))    

Fixed submission:
import fractions
n,*x=map(int,open(0).read().split())
x.sort()
a=[i-j for i,j in zip(x[1:],x[:-1])]
set(a)
a.sort()
b=[i for i in a if i%a[0]]
b.append(a[0])
if len(b)==1:
    print(*b)
else:
    ans=b[0]
    for i in b[1:]:
        ans=fractions.gcd(ans,i)
    print(ans)

Buggy python submission (verdict: Runtime Error):
import math
n,*x=map(int,open(0).read().split())
x.sort()
a=[i-j for i,j in zip(x[1:],x[:-1])]
set(a)
a.sort()
b=[i for i in a if i%a[0]]
b.append(a[0])
if len(b)==1:
    print(*b)
else:
    ans=b[0]
    for i,j in zip(b[1:],b[:-1]):
        ans=min(ans,gcd(i,j))
    print(ans) 

Fixed submission:
import fractions
n,*x=map(int,open(0).read().split())
x.sort()
a=[i-j for i,j in zip(x[1:],x[:-1])]
set(a)
a.sort()
b=[i for i in a if i%a[0]]
b.append(a[0])
if len(b)==1:
    print(*b)
else:
    ans=b[0]
    for i in b[1:]:
        ans=fractions.gcd(ans,i)
    print(ans)

Buggy python submission (verdict: Runtime Error):
import math
import itertools
n,*x=map(int,open(0).read().split())
x.sort()
a=[i-j for i,j in zip(x[1:],x[:-1])]
set(a)
a.sort()
b=[i for i in a if i%a[0]]
b.append(a[0])
if len(b)==1:
    print(*b)
else:
    ans=b[0]
    for i,j in itertools.combinations(b, 2):
        ans=min(ans,gcd(i,j))
    print(ans)    

Fixed submission:
import fractions
n,*x=map(int,open(0).read().split())
x.sort()
a=[i-j for i,j in zip(x[1:],x[:-1])]
set(a)
a.sort()
b=[i for i in a if i%a[0]]
b.append(a[0])
if len(b)==1:
    print(*b)
else:
    ans=b[0]
    for i in b[1:]:
        ans=fractions.gcd(ans,i)
    print(ans)

Buggy python submission (verdict: Runtime Error):
import math
n,*x=map(int,open(0).read().split())
x.sort()
a=[i-j for i,j in zip(x[1:],x[:-1])]
set(a)
ans=a[0]
b=a[0]
for i in a[1:]:
    ans=min(ans,math.gcd(i,b))
    b=i
print(ans)

Fixed submission:
import fractions
n,*x=map(int,open(0).read().split())
x.sort()
a=[i-j for i,j in zip(x[1:],x[:-1])]
set(a)
a.sort()
b=[i for i in a if i%a[0]]
b.append(a[0])
if len(b)==1:
    print(*b)
else:
    ans=b[0]
    for i in b[1:]:
        ans=fractions.gcd(ans,i)
    print(ans)

Buggy python submission (verdict: Runtime Error):
import math
n,*x=map(int,open(0).read().split())
x.sort()
a=[i-j for i,j in zip(x[1:],x[:-1])]
set(a)
ans=b=a[0]
for i in a[1:]:
    ans=min(ans,math.gcd(i,b))
    b=i
print(ans)

Fixed submission:
import fractions
n,*x=map(int,open(0).read().split())
x.sort()
a=[i-j for i,j in zip(x[1:],x[:-1])]
set(a)
a.sort()
b=[i for i in a if i%a[0]]
b.append(a[0])
if len(b)==1:
    print(*b)
else:
    ans=b[0]
    for i in b[1:]:
        ans=fractions.gcd(ans,i)
    print(ans)