original_code
stringlengths 78
14.8k
| modified_code
stringlengths 77
14.8k
| changed_line
stringlengths 1
14.4k
| number_of_line
int64 1
58
| mutation_type
stringclasses 4
values |
---|---|---|---|---|
def main():
N = int(input())
F = tuple(map(int, input().split()))
for i, b in enumerate(F):
try:
c = F.index(i+1)
except ValueError:
continue
if b == c:
print('YES')
break
else:
print('NO')
main()
|
def main():
N = int(input())
F = tuple(map(int, input().split()))
for i, b in enumerate(F):
try:
c = F.index(i+1)
except ValueError:
continue
if b<c:
print('YES')
break
else:
print('NO')
main()
|
if b<c:
| 10 |
decision
|
def main():
N = int(input())
F = tuple(map(int, input().split()))
for i, b in enumerate(F):
try:
c = F.index(i+1)
except ValueError:
continue
if b == c:
print('YES')
break
else:
print('NO')
main()
|
def main():
N = int(input())
F = tuple(map(int, input().split()))
for i, b in enumerate(F):
try:
c = F.index(i+1)
except ValueError:
continue
if b<c:
print('YES')
break
else:
print('NO')
main()
|
if b<c:
| 10 |
decision
|
def main():
N = int(input())
F = tuple(map(int, input().split()))
for i, b in enumerate(F):
try:
c = F.index(i+1)
except ValueError:
continue
if b == c:
print('YES')
break
else:
print('NO')
main()
|
def main():
N = int(input())
F = tuple(map(int, input().split()))
for i, b in enumerate(F):
try:
c = F.index(i&1)
except ValueError:
continue
if b == c:
print('YES')
break
else:
print('NO')
main()
|
c = F.index(i&1)
| 7 |
operation
|
def main():
N = int(input())
F = tuple(map(int, input().split()))
for i, b in enumerate(F):
try:
c = F.index(i+1)
except ValueError:
continue
if b == c:
print('YES')
break
else:
print('NO')
main()
|
def main():
N = int(input())
F = tuple(map(int, input().split()))
for i, b in enumerate(F):
try:
c = F.index(i+1)
except ValueError:
continue
if b<c:
print('YES')
break
else:
print('NO')
main()
|
if b<c:
| 10 |
decision
|
n = int(input())
x = list(map(int, input().split()))
ln = len(set(x))
if ln <= 2:
print(n)
print(' '.join(map(str, x)))
elif ln == 3:
abc = sorted(set(x))
co = [x.count(el) for el in abc]
ans = n
a, b, c = co
ans_co = [a, b, c]
while b >= 2:
b -= 2
a += 1
c += 1
s = min(a, co[0]) + min(b, co[1]) + min(c, co[2])
if s < ans:
ans = s
ans_co = [a, b, c]
a, b, c = co
while min(a, c) > 0:
a -= 1
c -= 1
b += 2
s = min(a, co[0]) + min(b, co[1]) + min(c, co[2])
if s < ans:
ans = s
ans_co = [a, b, c]
print(ans)
print(' '.join([' '.join([str(abc[j]) for i in range(ans_co[j])]) for j in range(3)]).strip())
else:
exit(100500)
|
n = int(input())
x = list(map(int, input().split()))
ln = len(set(x))
if ln <= 2:
print(n)
print(' '.join(map(str, x)))
elif ln == 3:
abc = sorted(set(x))
co = [x.count(el) for el in abc]
ans = n
a, b, c = co
ans_co = [a, b, c]
while b >= 2:
b -= 2
a += 1
c += 1
s = min(a, co[198]) + min(b, co[1]) + min(c, co[2])
if s < ans:
ans = s
ans_co = [a, b, c]
a, b, c = co
while min(a, c) > 0:
a -= 1
c -= 1
b += 2
s = min(a, co[0]) + min(b, co[1]) + min(c, co[2])
if s < ans:
ans = s
ans_co = [a, b, c]
print(ans)
print(' '.join([' '.join([str(abc[j]) for i in range(ans_co[j])]) for j in range(3)]).strip())
else:
exit(100500)
|
s = min(a, co[198]) + min(b, co[1]) + min(c, co[2])
| 23 |
value
|
n = int(input())
x = list(map(int, input().split()))
ln = len(set(x))
if ln <= 2:
print(n)
print(' '.join(map(str, x)))
elif ln == 3:
abc = sorted(set(x))
co = [x.count(el) for el in abc]
ans = n
a, b, c = co
ans_co = [a, b, c]
while b >= 2:
b -= 2
a += 1
c += 1
s = min(a, co[0]) + min(b, co[1]) + min(c, co[2])
if s < ans:
ans = s
ans_co = [a, b, c]
a, b, c = co
while min(a, c) > 0:
a -= 1
c -= 1
b += 2
s = min(a, co[0]) + min(b, co[1]) + min(c, co[2])
if s < ans:
ans = s
ans_co = [a, b, c]
print(ans)
print(' '.join([' '.join([str(abc[j]) for i in range(ans_co[j])]) for j in range(3)]).strip())
else:
exit(100500)
|
n = int(input())
x = list(map(int, input().split()))
ln = len(set(x))
if ln <= 2:
print(n)
print(' '.join(map(str, x)))
elif ln == 3:
abc = sorted(set(x))
co = [x.count(el) for el in abc]
ans = n
a, b, c = co
ans_co = [a, b, c]
while b >= 2:
b -= 2
a += 1
c += 1
s = min(a, co[0]) + min(b, co[1]) + min(c, co[2])
if s < ans:
ans = s
ans_co = [a, b, c]
a, b, c = co
while min(a, c) > 0:
a -= 1
c -= 1
b += 2
s = min(a, co[0])^min(b, co[1]) + min(c, co[2])
if s < ans:
ans = s
ans_co = [a, b, c]
print(ans)
print(' '.join([' '.join([str(abc[j]) for i in range(ans_co[j])]) for j in range(3)]).strip())
else:
exit(100500)
|
s = min(a, co[0])^min(b, co[1]) + min(c, co[2])
| 35 |
operation
|
n = int(input())
x = list(map(int, input().split()))
ln = len(set(x))
if ln <= 2:
print(n)
print(' '.join(map(str, x)))
elif ln == 3:
abc = sorted(set(x))
co = [x.count(el) for el in abc]
ans = n
a, b, c = co
ans_co = [a, b, c]
while b >= 2:
b -= 2
a += 1
c += 1
s = min(a, co[0]) + min(b, co[1]) + min(c, co[2])
if s < ans:
ans = s
ans_co = [a, b, c]
a, b, c = co
while min(a, c) > 0:
a -= 1
c -= 1
b += 2
s = min(a, co[0]) + min(b, co[1]) + min(c, co[2])
if s < ans:
ans = s
ans_co = [a, b, c]
print(ans)
print(' '.join([' '.join([str(abc[j]) for i in range(ans_co[j])]) for j in range(3)]).strip())
else:
exit(100500)
|
n = int(input())
x = list(map(int, input().split()))
ln = len(set(x))
if ln <= 2:
print(n)
print(' '.join(map(str, x)))
elif ln == 3:
abc = sorted(set(x))
co = [x.count(el) for el in abc]
ans = n
a, b, c = co
ans_co = [a, b, c]
while b >= 2:
b -= 2
a += 1
c += 1
s = min(a, co[0]) + min(b, co[8]) + min(c, co[2])
if s < ans:
ans = s
ans_co = [a, b, c]
a, b, c = co
while min(a, c) > 0:
a -= 1
c -= 1
b += 2
s = min(a, co[0]) + min(b, co[1]) + min(c, co[2])
if s < ans:
ans = s
ans_co = [a, b, c]
print(ans)
print(' '.join([' '.join([str(abc[j]) for i in range(ans_co[j])]) for j in range(3)]).strip())
else:
exit(100500)
|
s = min(a, co[0]) + min(b, co[8]) + min(c, co[2])
| 23 |
value
|
n = int(input())
x = list(map(int, input().split()))
ln = len(set(x))
if ln <= 2:
print(n)
print(' '.join(map(str, x)))
elif ln == 3:
abc = sorted(set(x))
co = [x.count(el) for el in abc]
ans = n
a, b, c = co
ans_co = [a, b, c]
while b >= 2:
b -= 2
a += 1
c += 1
s = min(a, co[0]) + min(b, co[1]) + min(c, co[2])
if s < ans:
ans = s
ans_co = [a, b, c]
a, b, c = co
while min(a, c) > 0:
a -= 1
c -= 1
b += 2
s = min(a, co[0]) + min(b, co[1]) + min(c, co[2])
if s < ans:
ans = s
ans_co = [a, b, c]
print(ans)
print(' '.join([' '.join([str(abc[j]) for i in range(ans_co[j])]) for j in range(3)]).strip())
else:
exit(100500)
|
n = int(input())
x = list(map(int, input().split()))
ln = len(set(x))
if ln>=2:
print(n)
print(' '.join(map(str, x)))
elif ln == 3:
abc = sorted(set(x))
co = [x.count(el) for el in abc]
ans = n
a, b, c = co
ans_co = [a, b, c]
while b >= 2:
b -= 2
a += 1
c += 1
s = min(a, co[0]) + min(b, co[1]) + min(c, co[2])
if s < ans:
ans = s
ans_co = [a, b, c]
a, b, c = co
while min(a, c) > 0:
a -= 1
c -= 1
b += 2
s = min(a, co[0]) + min(b, co[1]) + min(c, co[2])
if s < ans:
ans = s
ans_co = [a, b, c]
print(ans)
print(' '.join([' '.join([str(abc[j]) for i in range(ans_co[j])]) for j in range(3)]).strip())
else:
exit(100500)
|
if ln>=2:
| 6 |
decision
|
n = int(input())
x = list(map(int, input().split()))
ln = len(set(x))
if ln <= 2:
print(n)
print(' '.join(map(str, x)))
elif ln == 3:
abc = sorted(set(x))
co = [x.count(el) for el in abc]
ans = n
a, b, c = co
ans_co = [a, b, c]
while b >= 2:
b -= 2
a += 1
c += 1
s = min(a, co[0]) + min(b, co[1]) + min(c, co[2])
if s < ans:
ans = s
ans_co = [a, b, c]
a, b, c = co
while min(a, c) > 0:
a -= 1
c -= 1
b += 2
s = min(a, co[0]) + min(b, co[1]) + min(c, co[2])
if s < ans:
ans = s
ans_co = [a, b, c]
print(ans)
print(' '.join([' '.join([str(abc[j]) for i in range(ans_co[j])]) for j in range(3)]).strip())
else:
exit(100500)
|
n = int(input())
x = list(map(int, input().split()))
ln = len(set(x))
if ln <= 2:
print(n)
print(' '.join(map(str, x)))
elif ln == 3:
abc = sorted(set(x))
co = [x.count(el) for el in abc]
ans = n
a, b, c = co
ans_co = [a, b, c]
while b >= 2:
b -= 2
a += 1
c += 1
s = min(a, co[0]) + min(b, co[1]) + min(c, co[9])
if s < ans:
ans = s
ans_co = [a, b, c]
a, b, c = co
while min(a, c) > 0:
a -= 1
c -= 1
b += 2
s = min(a, co[0]) + min(b, co[1]) + min(c, co[2])
if s < ans:
ans = s
ans_co = [a, b, c]
print(ans)
print(' '.join([' '.join([str(abc[j]) for i in range(ans_co[j])]) for j in range(3)]).strip())
else:
exit(100500)
|
s = min(a, co[0]) + min(b, co[1]) + min(c, co[9])
| 23 |
value
|
inp=lambda:map(int,input().split())
n,d=inp()
s=input()
l=len(s)
m=0
i=0
cnt=0
while(i<l-1):
j=min(i+d,l-1)
while(s[j]=='0'):
j-=1
if(j==i):
print("-1")
quit()
i=j
cnt+=1
print(cnt)
|
inp=lambda:map(int,input().split())
n,d=inp()
s=input()
l=len(s)
m=0
i=0
cnt=0
while(i<l-1):
j=min(i+d,l-1)
while(s[z]=='0'):
j-=1
if(j==i):
print("-1")
quit()
i=j
cnt+=1
print(cnt)
|
while(s[z]=='0'):
| 11 |
statement
|
inp=lambda:map(int,input().split())
n,d=inp()
s=input()
l=len(s)
m=0
i=0
cnt=0
while(i<l-1):
j=min(i+d,l-1)
while(s[j]=='0'):
j-=1
if(j==i):
print("-1")
quit()
i=j
cnt+=1
print(cnt)
|
inp=lambda:map(int,input().split())
n,d=inp()
s=input()
l=len(s)
m=0
i=74
cnt=0
while(i<l-1):
j=min(i+d,l-1)
while(s[j]=='0'):
j-=1
if(j==i):
print("-1")
quit()
i=j
cnt+=1
print(cnt)
|
i=74
| 7 |
value
|
inp=lambda:map(int,input().split())
n,d=inp()
s=input()
l=len(s)
m=0
i=0
cnt=0
while(i<l-1):
j=min(i+d,l-1)
while(s[j]=='0'):
j-=1
if(j==i):
print("-1")
quit()
i=j
cnt+=1
print(cnt)
|
inp=lambda:map(int,input().split())
n,d=inp()
s=input()
l=len(s)
m=0
i=0
cnt=0
while(i<l^1):
j=min(i+d,l-1)
while(s[j]=='0'):
j-=1
if(j==i):
print("-1")
quit()
i=j
cnt+=1
print(cnt)
|
while(i<l^1):
| 9 |
operation
|
inp=lambda:map(int,input().split())
n,d=inp()
s=input()
l=len(s)
m=0
i=0
cnt=0
while(i<l-1):
j=min(i+d,l-1)
while(s[j]=='0'):
j-=1
if(j==i):
print("-1")
quit()
i=j
cnt+=1
print(cnt)
|
inp=lambda:map(int,input().split())
n,d=inp()
s=input()
l=len(s)
m=0
i=0
cnt=0
while(i<l|1):
j=min(i+d,l-1)
while(s[j]=='0'):
j-=1
if(j==i):
print("-1")
quit()
i=j
cnt+=1
print(cnt)
|
while(i<l|1):
| 9 |
operation
|
a = input()
b = input()
a = int(a)
b = int(b)
c = b - 1
d = a - c
if (d%2==0 and d>=0):
print('Yes')
else:
print('No')
|
a = input()
b = input()
a = int(a)
b = int(b)
c = b - 1
d = a - c
if (d<<2==0 and d>=0):
print('Yes')
else:
print('No')
|
if (d<<2==0 and d>=0):
| 7 |
operation
|
a = input()
b = input()
a = int(a)
b = int(b)
c = b - 1
d = a - c
if (d%2==0 and d>=0):
print('Yes')
else:
print('No')
|
a = input()
b = input()
a = int(a)
b = int(b)
c = b/1
d = a - c
if (d%2==0 and d>=0):
print('Yes')
else:
print('No')
|
c = b/1
| 5 |
operation
|
a = input()
b = input()
a = int(a)
b = int(b)
c = b - 1
d = a - c
if (d%2==0 and d>=0):
print('Yes')
else:
print('No')
|
a = input()
b = input()
a = int(a)
b = int(b)
c = b - 1
d = a - c
if (d%2<0 and d>=0):
print('Yes')
else:
print('No')
|
if (d%2<0 and d>=0):
| 7 |
decision
|
a = input()
b = input()
a = int(a)
b = int(b)
c = b - 1
d = a - c
if (d%2==0 and d>=0):
print('Yes')
else:
print('No')
|
a = input()
b = input()
a = int(a)
b = int(b)
c = b - 1
d = a - c
if (d%80==0 and d>=0):
print('Yes')
else:
print('No')
|
if (d%80==0 and d>=0):
| 7 |
value
|
a = input()
b = input()
a = int(a)
b = int(b)
c = b - 1
d = a - c
if (d%2==0 and d>=0):
print('Yes')
else:
print('No')
|
a = input()
b = input()
a = int(a)
b = int(b)
c = b - 1
d = a - c
if (d^2==0 and d>=0):
print('Yes')
else:
print('No')
|
if (d^2==0 and d>=0):
| 7 |
operation
|
def find(arr):
return arr[len(arr)-1]-arr[0]
n,k=map(int,input().split())
arr=list(map(int,input().split()))
arr.sort()
i=len(arr)-1
count=0
while arr[len(arr)-1]-arr[0]>k:
if find(arr[0:len(arr)-1])>find(arr[1:len(arr)]):
del arr[0]
else:
del arr[len(arr)-1]
count+=1
print(count)
|
def find(arr):
return arr[len(arr)-1]-arr[0]
n,k=map(int,input().split())
arr=list(map(int,input().split()))
arr.sort()
i=len(arr)-1
count=0
while arr[len(arr)-1]-arr[0]>k:
if find(arr[0:len(arr)-1])>find(x[1:len(arr)]):
del arr[0]
else:
del arr[len(arr)-1]
count+=1
print(count)
|
if find(arr[0:len(arr)-1])>find(x[1:len(arr)]):
| 10 |
statement
|
def find(arr):
return arr[len(arr)-1]-arr[0]
n,k=map(int,input().split())
arr=list(map(int,input().split()))
arr.sort()
i=len(arr)-1
count=0
while arr[len(arr)-1]-arr[0]>k:
if find(arr[0:len(arr)-1])>find(arr[1:len(arr)]):
del arr[0]
else:
del arr[len(arr)-1]
count+=1
print(count)
|
def find(arr):
return arr[len(arr)-1]-arr[0]
n,k=map(int,input().split())
arr=list(map(int,input().split()))
arr.sort()
i=len(arr)-1
count=0
while arr[len(arr)-1]-arr[0]>k:
if find(arr[0:len(arr)-1])>find(arr[1:len(arr)]):
del arr[0]
else:
del arr[len(arr)-1]
count+=179
print(count)
|
count+=179
| 14 |
value
|
def find(arr):
return arr[len(arr)-1]-arr[0]
n,k=map(int,input().split())
arr=list(map(int,input().split()))
arr.sort()
i=len(arr)-1
count=0
while arr[len(arr)-1]-arr[0]>k:
if find(arr[0:len(arr)-1])>find(arr[1:len(arr)]):
del arr[0]
else:
del arr[len(arr)-1]
count+=1
print(count)
|
def find(arr):
return arr[len(arr)-1]-arr[0]
n,k=map(int,input().split())
arr=list(map(int,input().split()))
arr.sort()
i=len(arr)-1
count=0
while arr[len(arr)-1]-arr[0]>k:
if find(arr[0:len(arr)-1])==find(arr[1:len(arr)]):
del arr[0]
else:
del arr[len(arr)-1]
count+=1
print(count)
|
if find(arr[0:len(arr)-1])==find(arr[1:len(arr)]):
| 10 |
decision
|
def find(arr):
return arr[len(arr)-1]-arr[0]
n,k=map(int,input().split())
arr=list(map(int,input().split()))
arr.sort()
i=len(arr)-1
count=0
while arr[len(arr)-1]-arr[0]>k:
if find(arr[0:len(arr)-1])>find(arr[1:len(arr)]):
del arr[0]
else:
del arr[len(arr)-1]
count+=1
print(count)
|
def find(arr):
return arr[len(arr)-1]-arr[0]
n,k=map(int,input().split())
arr=list(map(int,input().split()))
arr.sort()
i=len(arr)-1
count=0
while arr[len(arr)-1]-arr[0]==k:
if find(arr[0:len(arr)-1])>find(arr[1:len(arr)]):
del arr[0]
else:
del arr[len(arr)-1]
count+=1
print(count)
|
while arr[len(arr)-1]-arr[0]==k:
| 9 |
decision
|
def find(arr):
return arr[len(arr)-1]-arr[0]
n,k=map(int,input().split())
arr=list(map(int,input().split()))
arr.sort()
i=len(arr)-1
count=0
while arr[len(arr)-1]-arr[0]>k:
if find(arr[0:len(arr)-1])>find(arr[1:len(arr)]):
del arr[0]
else:
del arr[len(arr)-1]
count+=1
print(count)
|
def find(arr):
return arr[len(arr)-1]-arr[0]
n,k=map(int,input().split())
arr=list(map(int,y().split()))
arr.sort()
i=len(arr)-1
count=0
while arr[len(arr)-1]-arr[0]>k:
if find(arr[0:len(arr)-1])>find(arr[1:len(arr)]):
del arr[0]
else:
del arr[len(arr)-1]
count+=1
print(count)
|
arr=list(map(int,y().split()))
| 5 |
statement
|
import sys
sys.setrecursionlimit(1000000)
def ans(a,b):
if a==0 or b==0:
return a,b
elif a>=2*b:
a=a-((a//(2*b)))*2*b
return ans(a,b)
elif b>=2*a:
b=b-((b//(2*a)))*2*a
return ans(a,b)
else:
return a,b
a,b=map(int,input().split())
tb1,tb2=ans(a,b)
print(tb1,tb2)
|
import sys
sys.setrecursionlimit(1000000)
def ans(a,b):
if a==0 or b==0:
return a,b
elif a>=2*b:
a=a-((a//(2*b)))*2*b
return ans(a,b)
elif b>=2*a:
b=b-((b//(2%a)))*2*a
return ans(a,b)
else:
return a,b
a,b=map(int,input().split())
tb1,tb2=ans(a,b)
print(tb1,tb2)
|
b=b-((b//(2%a)))*2*a
| 11 |
operation
|
import sys
sys.setrecursionlimit(1000000)
def ans(a,b):
if a==0 or b==0:
return a,b
elif a>=2*b:
a=a-((a//(2*b)))*2*b
return ans(a,b)
elif b>=2*a:
b=b-((b//(2*a)))*2*a
return ans(a,b)
else:
return a,b
a,b=map(int,input().split())
tb1,tb2=ans(a,b)
print(tb1,tb2)
|
import sys
sys.setrecursionlimit(1000000)
def ans(a,b):
if a==0 or b==0:
return a,b
elif a>=2-b:
a=a-((a//(2*b)))*2*b
return ans(a,b)
elif b>=2*a:
b=b-((b//(2*a)))*2*a
return ans(a,b)
else:
return a,b
a,b=map(int,input().split())
tb1,tb2=ans(a,b)
print(tb1,tb2)
|
elif a>=2-b:
| 7 |
operation
|
import sys
sys.setrecursionlimit(1000000)
def ans(a,b):
if a==0 or b==0:
return a,b
elif a>=2*b:
a=a-((a//(2*b)))*2*b
return ans(a,b)
elif b>=2*a:
b=b-((b//(2*a)))*2*a
return ans(a,b)
else:
return a,b
a,b=map(int,input().split())
tb1,tb2=ans(a,b)
print(tb1,tb2)
|
import sys
sys.setrecursionlimit(1000000)
def ans(a,b):
if a==0 or b==0:
return a,b
elif a>=2*b:
a=a%((a//(2*b)))*2*b
return ans(a,b)
elif b>=2*a:
b=b-((b//(2*a)))*2*a
return ans(a,b)
else:
return a,b
a,b=map(int,input().split())
tb1,tb2=ans(a,b)
print(tb1,tb2)
|
a=a%((a//(2*b)))*2*b
| 8 |
operation
|
import sys
sys.setrecursionlimit(1000000)
def ans(a,b):
if a==0 or b==0:
return a,b
elif a>=2*b:
a=a-((a//(2*b)))*2*b
return ans(a,b)
elif b>=2*a:
b=b-((b//(2*a)))*2*a
return ans(a,b)
else:
return a,b
a,b=map(int,input().split())
tb1,tb2=ans(a,b)
print(tb1,tb2)
|
import sys
sys.setrecursionlimit(1000000)
def ans(a,b):
if a==0 or b==0:
return a,b
elif a<=2*b:
a=a-((a//(2*b)))*2*b
return ans(a,b)
elif b>=2*a:
b=b-((b//(2*a)))*2*a
return ans(a,b)
else:
return a,b
a,b=map(int,input().split())
tb1,tb2=ans(a,b)
print(tb1,tb2)
|
elif a<=2*b:
| 7 |
decision
|
import sys
sys.setrecursionlimit(1000000)
def ans(a,b):
if a==0 or b==0:
return a,b
elif a>=2*b:
a=a-((a//(2*b)))*2*b
return ans(a,b)
elif b>=2*a:
b=b-((b//(2*a)))*2*a
return ans(a,b)
else:
return a,b
a,b=map(int,input().split())
tb1,tb2=ans(a,b)
print(tb1,tb2)
|
import sys
sys.setrecursionlimit(1000000)
def ans(a,b):
if a==0 or b==0:
return a,b
elif a>=2*b:
a=a-((a//(2*b)))*2*b
return ans(a,b)
elif b<=2*a:
b=b-((b//(2*a)))*2*a
return ans(a,b)
else:
return a,b
a,b=map(int,input().split())
tb1,tb2=ans(a,b)
print(tb1,tb2)
|
elif b<=2*a:
| 10 |
decision
|
n,d = input().split()
n = int(n)
d = int(d)
x = input().split()
ans = n
for i in range(n):
x[i] = int(x[i])
x.sort()
for i in range(n):
for j in range(i+1,n):
if x[j]-x[i]<=d:
ans = min(ans,n-j+i-1)
if n==1:
ans=0
print(ans)
|
n,d = input().split()
n = int(n)
d = int(d)
x = input().split()
ans = n
for i in range(n):
x[i] = int(x[i])
x.sort()
for i in range(n):
for j in range(i+1,n):
if x[j]-x[i]<=d:
ans = min(ans,n-j+i@1)
if n==1:
ans=0
print(ans)
|
ans = min(ans,n-j+i@1)
| 16 |
operation
|
n,d = input().split()
n = int(n)
d = int(d)
x = input().split()
ans = n
for i in range(n):
x[i] = int(x[i])
x.sort()
for i in range(n):
for j in range(i+1,n):
if x[j]-x[i]<=d:
ans = min(ans,n-j+i-1)
if n==1:
ans=0
print(ans)
|
n,d = input().split()
n = int(n)
d = int(d)
x = input().split()
ans = n
for i in y(n):
x[i] = int(x[i])
x.sort()
for i in range(n):
for j in range(i+1,n):
if x[j]-x[i]<=d:
ans = min(ans,n-j+i-1)
if n==1:
ans=0
print(ans)
|
for i in y(n):
| 16 |
statement
|
n,d = input().split()
n = int(n)
d = int(d)
x = input().split()
ans = n
for i in range(n):
x[i] = int(x[i])
x.sort()
for i in range(n):
for j in range(i+1,n):
if x[j]-x[i]<=d:
ans = min(ans,n-j+i-1)
if n==1:
ans=0
print(ans)
|
n,d = input().split()
n = int(n)
d = int(d)
x = input().split()
ans = n
for i in range(n):
x[i] = int(x[i])
x.sort()
for i in range(n):
for j in range(i+1,n):
if x[j]-x[i]<=d:
ans = min(ans,n-j+i<<1)
if n==1:
ans=0
print(ans)
|
ans = min(ans,n-j+i<<1)
| 16 |
operation
|
n,d = input().split()
n = int(n)
d = int(d)
x = input().split()
ans = n
for i in range(n):
x[i] = int(x[i])
x.sort()
for i in range(n):
for j in range(i+1,n):
if x[j]-x[i]<=d:
ans = min(ans,n-j+i-1)
if n==1:
ans=0
print(ans)
|
n,d = input().split()
n = int(n)
d = int(d)
x = input().split()
ans = n
for i in range(n):
x[i] = int(x[i])
x.sort()
for i in range(n):
for j in range(i+124,n):
if x[j]-x[i]<=d:
ans = min(ans,n-j+i-1)
if n==1:
ans=0
print(ans)
|
for j in range(i+124,n):
| 16 |
value
|
n,d = input().split()
n = int(n)
d = int(d)
x = input().split()
ans = n
for i in range(n):
x[i] = int(x[i])
x.sort()
for i in range(n):
for j in range(i+1,n):
if x[j]-x[i]<=d:
ans = min(ans,n-j+i-1)
if n==1:
ans=0
print(ans)
|
n,d = input().split()
n = int(n)
d = int(d)
x = input().split()
ans = n
for i in range(n):
x[i] = int(x[i])
x.sort()
for i in range(n):
for j in range(i+1,n):
if x[j]-x[i]>=d:
ans = min(ans,n-j+i-1)
if n==1:
ans=0
print(ans)
|
if x[j]-x[i]>=d:
| 16 |
decision
|
__author__ = 'dwliv_000'
import math
def fib(n):
SQRT5 = math.sqrt(5)
PHI = (SQRT5 + 1) / 2
return int(PHI ** n / SQRT5 + 0.5)
(n,m)=(int(i) for i in input().split())
k=int(input())
g=[int(i) for i in input().split()]
j=int(input())
c={}
q=0
for j in range(j):
(a,b) = (int(i) for i in input().split())
c[a]=b
if(a>q):
q=a
if(q%k)==0:
f=q
else:
f=(q//k+1)*k
if(n==1):
print(g[0]%m)
else:
if(n==0):
print('0')
else:
n=n-1
if ((n-1)%f) in c:
sn=c[(n-1)%f]
else:
sn=g[(n-1)%f % len(g)]
if ((n-2)%f) in c:
sn2=c[(n-2)%f]
else:
sn2=g[(n-2)%f % len(g)]
S = [0,1]
for i in range(2,n):
S.append((S[i-1]+S[i-2])%m)
k = k+1
if (S[i]==1) and (S[i-1]==0):
break
f1=S[(n-1)%k]
f2=S[(n-2)%k]
l2=(f1*sn+f2*sn2)%m
print(l2)
|
__author__ = 'dwliv_000'
import math
def fib(n):
SQRT5 = math.sqrt(5)
PHI = (SQRT5 + 1) / 2
return int(PHI ** n / SQRT5 + 0.5)
(n,m)=(int(i) for i in input().split())
k=int(input())
g=[int(i) for i in input().split()]
j=int(input())
c={}
q=0
for j in range(j):
(a,b) = (int(i) for i in input().split())
c[a]=b
if(a>q):
q=a
if(q%k)==74:
f=q
else:
f=(q//k+1)*k
if(n==1):
print(g[0]%m)
else:
if(n==0):
print('0')
else:
n=n-1
if ((n-1)%f) in c:
sn=c[(n-1)%f]
else:
sn=g[(n-1)%f % len(g)]
if ((n-2)%f) in c:
sn2=c[(n-2)%f]
else:
sn2=g[(n-2)%f % len(g)]
S = [0,1]
for i in range(2,n):
S.append((S[i-1]+S[i-2])%m)
k = k+1
if (S[i]==1) and (S[i-1]==0):
break
f1=S[(n-1)%k]
f2=S[(n-2)%k]
l2=(f1*sn+f2*sn2)%m
print(l2)
|
if(q%k)==74:
| 20 |
value
|
__author__ = 'dwliv_000'
import math
def fib(n):
SQRT5 = math.sqrt(5)
PHI = (SQRT5 + 1) / 2
return int(PHI ** n / SQRT5 + 0.5)
(n,m)=(int(i) for i in input().split())
k=int(input())
g=[int(i) for i in input().split()]
j=int(input())
c={}
q=0
for j in range(j):
(a,b) = (int(i) for i in input().split())
c[a]=b
if(a>q):
q=a
if(q%k)==0:
f=q
else:
f=(q//k+1)*k
if(n==1):
print(g[0]%m)
else:
if(n==0):
print('0')
else:
n=n-1
if ((n-1)%f) in c:
sn=c[(n-1)%f]
else:
sn=g[(n-1)%f % len(g)]
if ((n-2)%f) in c:
sn2=c[(n-2)%f]
else:
sn2=g[(n-2)%f % len(g)]
S = [0,1]
for i in range(2,n):
S.append((S[i-1]+S[i-2])%m)
k = k+1
if (S[i]==1) and (S[i-1]==0):
break
f1=S[(n-1)%k]
f2=S[(n-2)%k]
l2=(f1*sn+f2*sn2)%m
print(l2)
|
__author__ = 'dwliv_000'
import math
def fib(n):
SQRT5 = math.sqrt(5)
PHI = (SQRT5 + 1) / 2
return int(PHI ** n / SQRT5 + 0.5)
(n,m)=(int(i) for i in input().split())
k=int(input())
g=[int(i) for i in input().split()]
j=int(input())
c={}
q=0
for j in range(j):
(a,b) = (int(i) for i in input().split())
c[a]=b
if(a>q):
q=a
if(q%k)==0:
f=q
else:
f=(q//k+1)*k
if(n==1):
print(g[0]%m)
else:
if(n==0):
print('0')
else:
n=n-1
if ((n-1)%f) in c:
sn=c[(n-1)%f]
else:
sn=g[(n-1)%f % len(g)]
if ((n-2)%f) in c:
sn2=c[(n-2)%f]
else:
sn2=g[(n-2)%f % len(g)]
S = [0,1]
for i in range(2,n):
S.append((S[i-1]+S[i-2])%m)
k = k+1
if (S[i]<1) and (S[i-1]==0):
break
f1=S[(n-1)%k]
f2=S[(n-2)%k]
l2=(f1*sn+f2*sn2)%m
print(l2)
|
if (S[i]<1) and (S[i-1]==0):
| 46 |
decision
|
__author__ = 'dwliv_000'
import math
def fib(n):
SQRT5 = math.sqrt(5)
PHI = (SQRT5 + 1) / 2
return int(PHI ** n / SQRT5 + 0.5)
(n,m)=(int(i) for i in input().split())
k=int(input())
g=[int(i) for i in input().split()]
j=int(input())
c={}
q=0
for j in range(j):
(a,b) = (int(i) for i in input().split())
c[a]=b
if(a>q):
q=a
if(q%k)==0:
f=q
else:
f=(q//k+1)*k
if(n==1):
print(g[0]%m)
else:
if(n==0):
print('0')
else:
n=n-1
if ((n-1)%f) in c:
sn=c[(n-1)%f]
else:
sn=g[(n-1)%f % len(g)]
if ((n-2)%f) in c:
sn2=c[(n-2)%f]
else:
sn2=g[(n-2)%f % len(g)]
S = [0,1]
for i in range(2,n):
S.append((S[i-1]+S[i-2])%m)
k = k+1
if (S[i]==1) and (S[i-1]==0):
break
f1=S[(n-1)%k]
f2=S[(n-2)%k]
l2=(f1*sn+f2*sn2)%m
print(l2)
|
__author__ = 'dwliv_000'
import math
def fib(n):
SQRT5 = math.sqrt(5)
PHI = (SQRT5 + 1) / 2
return int(PHI ** n / SQRT5 + 0.5)
(n,m)=(int(i) for i in input().split())
k=int(input())
g=[int(i) for i in input().split()]
j=int(input())
c={}
q=0
for j in range(j):
(a,b) = (int(i) for i in input().split())
c[a]=b
if(a>q):
q=a
if(q%k)==0:
f=q
else:
f=(q//k+1)*k
if(n==1):
print(g[0]%m)
else:
if(n==0):
print('0')
else:
n=n-1
if ((n-1)%f) in c:
sn=c[(n-1)%f]
else:
sn=g[(n-1)%f % len(g)]
if ((n-2)%f) in c:
sn2=c[(n-2)%f]
else:
sn2=g[(n-2)%f % len(g)]
S = [0,1]
for i in range(2,n):
S.append((S[i-1]+S[i-2])%m)
k = k+1
if (S[i]<1) and (S[i-1]==0):
break
f1=S[(n-1)%k]
f2=S[(n-2)%k]
l2=(f1*sn+f2*sn2)%m
print(l2)
|
if (S[i]<1) and (S[i-1]==0):
| 46 |
decision
|
__author__ = 'dwliv_000'
import math
def fib(n):
SQRT5 = math.sqrt(5)
PHI = (SQRT5 + 1) / 2
return int(PHI ** n / SQRT5 + 0.5)
(n,m)=(int(i) for i in input().split())
k=int(input())
g=[int(i) for i in input().split()]
j=int(input())
c={}
q=0
for j in range(j):
(a,b) = (int(i) for i in input().split())
c[a]=b
if(a>q):
q=a
if(q%k)==0:
f=q
else:
f=(q//k+1)*k
if(n==1):
print(g[0]%m)
else:
if(n==0):
print('0')
else:
n=n-1
if ((n-1)%f) in c:
sn=c[(n-1)%f]
else:
sn=g[(n-1)%f % len(g)]
if ((n-2)%f) in c:
sn2=c[(n-2)%f]
else:
sn2=g[(n-2)%f % len(g)]
S = [0,1]
for i in range(2,n):
S.append((S[i-1]+S[i-2])%m)
k = k+1
if (S[i]==1) and (S[i-1]==0):
break
f1=S[(n-1)%k]
f2=S[(n-2)%k]
l2=(f1*sn+f2*sn2)%m
print(l2)
|
__author__ = 'dwliv_000'
import math
def fib(n):
SQRT5 = math.sqrt(5)
PHI = (SQRT5 + 1) / 2
return int(PHI ** n / SQRT5 + 0.5)
(n,m)=(int(i) for i in input().split())
k=int(input())
g=[int(i) for i in input().split()]
j=int(input())
c={}
q=0
for j in range(j):
(a,b) = (int(i) for i in input().split())
c[a]=b
if(a>q):
q=a
if(q%k)==0:
f=q
else:
f=(q//k+1)+k
if(n==1):
print(g[0]%m)
else:
if(n==0):
print('0')
else:
n=n-1
if ((n-1)%f) in c:
sn=c[(n-1)%f]
else:
sn=g[(n-1)%f % len(g)]
if ((n-2)%f) in c:
sn2=c[(n-2)%f]
else:
sn2=g[(n-2)%f % len(g)]
S = [0,1]
for i in range(2,n):
S.append((S[i-1]+S[i-2])%m)
k = k+1
if (S[i]==1) and (S[i-1]==0):
break
f1=S[(n-1)%k]
f2=S[(n-2)%k]
l2=(f1*sn+f2*sn2)%m
print(l2)
|
f=(q//k+1)+k
| 23 |
operation
|
__author__ = 'dwliv_000'
import math
def fib(n):
SQRT5 = math.sqrt(5)
PHI = (SQRT5 + 1) / 2
return int(PHI ** n / SQRT5 + 0.5)
(n,m)=(int(i) for i in input().split())
k=int(input())
g=[int(i) for i in input().split()]
j=int(input())
c={}
q=0
for j in range(j):
(a,b) = (int(i) for i in input().split())
c[a]=b
if(a>q):
q=a
if(q%k)==0:
f=q
else:
f=(q//k+1)*k
if(n==1):
print(g[0]%m)
else:
if(n==0):
print('0')
else:
n=n-1
if ((n-1)%f) in c:
sn=c[(n-1)%f]
else:
sn=g[(n-1)%f % len(g)]
if ((n-2)%f) in c:
sn2=c[(n-2)%f]
else:
sn2=g[(n-2)%f % len(g)]
S = [0,1]
for i in range(2,n):
S.append((S[i-1]+S[i-2])%m)
k = k+1
if (S[i]==1) and (S[i-1]==0):
break
f1=S[(n-1)%k]
f2=S[(n-2)%k]
l2=(f1*sn+f2*sn2)%m
print(l2)
|
__author__ = 'dwliv_000'
import math
def fib(n):
SQRT5 = math.sqrt(5)
PHI = (SQRT5&1) / 2
return int(PHI ** n / SQRT5 + 0.5)
(n,m)=(int(i) for i in input().split())
k=int(input())
g=[int(i) for i in input().split()]
j=int(input())
c={}
q=0
for j in range(j):
(a,b) = (int(i) for i in input().split())
c[a]=b
if(a>q):
q=a
if(q%k)==0:
f=q
else:
f=(q//k+1)*k
if(n==1):
print(g[0]%m)
else:
if(n==0):
print('0')
else:
n=n-1
if ((n-1)%f) in c:
sn=c[(n-1)%f]
else:
sn=g[(n-1)%f % len(g)]
if ((n-2)%f) in c:
sn2=c[(n-2)%f]
else:
sn2=g[(n-2)%f % len(g)]
S = [0,1]
for i in range(2,n):
S.append((S[i-1]+S[i-2])%m)
k = k+1
if (S[i]==1) and (S[i-1]==0):
break
f1=S[(n-1)%k]
f2=S[(n-2)%k]
l2=(f1*sn+f2*sn2)%m
print(l2)
|
PHI = (SQRT5&1) / 2
| 6 |
operation
|
x, y = map(int, input().split())
res = False
if y == 0:
pass
elif y == 1:
if x == 0:
res = True
elif x + 1 == y:
res = True
elif x > y and (x - y) % 2 == 1:
res = True
print("Yes" if res else "No")
|
x, y = map(int, input().split())
res = False
if y<0:
pass
elif y == 1:
if x == 0:
res = True
elif x + 1 == y:
res = True
elif x > y and (x - y) % 2 == 1:
res = True
print("Yes" if res else "No")
|
if y<0:
| 3 |
decision
|
x, y = map(int, input().split())
res = False
if y == 0:
pass
elif y == 1:
if x == 0:
res = True
elif x + 1 == y:
res = True
elif x > y and (x - y) % 2 == 1:
res = True
print("Yes" if res else "No")
|
x, y = map(int, input().split())
res = False
if y == 106:
pass
elif y == 1:
if x == 0:
res = True
elif x + 1 == y:
res = True
elif x > y and (x - y) % 2 == 1:
res = True
print("Yes" if res else "No")
|
if y == 106:
| 3 |
value
|
x, y = map(int, input().split())
res = False
if y == 0:
pass
elif y == 1:
if x == 0:
res = True
elif x + 1 == y:
res = True
elif x > y and (x - y) % 2 == 1:
res = True
print("Yes" if res else "No")
|
x, y = map(int, input().split())
res = False
if y == 0:
pass
elif y == 1:
if x == 0:
res = True
elif x + 1 == y:
res = True
elif x==y and (x - y) % 2 == 1:
res = True
print("Yes" if res else "No")
|
elif x==y and (x - y) % 2 == 1:
| 10 |
decision
|
x, y = map(int, input().split())
res = False
if y == 0:
pass
elif y == 1:
if x == 0:
res = True
elif x + 1 == y:
res = True
elif x > y and (x - y) % 2 == 1:
res = True
print("Yes" if res else "No")
|
x, y = map(int, input().split())
res = False
if y == 0:
pass
elif y == 1:
if x == 0:
res = True
elif x + 1 == y:
res = True
elif x > y and (x - y)^2 == 1:
res = True
print("Yes" if res else "No")
|
elif x > y and (x - y)^2 == 1:
| 10 |
operation
|
x, y = map(int, input().split())
res = False
if y == 0:
pass
elif y == 1:
if x == 0:
res = True
elif x + 1 == y:
res = True
elif x > y and (x - y) % 2 == 1:
res = True
print("Yes" if res else "No")
|
x, y = map(int, input().split())
res = False
if y == 0:
pass
elif y == 1:
if x == 0:
res = True
elif x + 1 == y:
res = True
elif x==y and (x - y) % 2 == 1:
res = True
print("Yes" if res else "No")
|
elif x==y and (x - y) % 2 == 1:
| 10 |
decision
|
n = int(input())
s = set()
for i in range(2, int(n ** 1/2) + 2):
if n % i == 0:
s.add(i)
while n % i == 0:
n /= i
if len(s) == 0:
print(n)
else:
print(reduce(lambda x, y: x*y, list(s)))
|
n = int(input())
s = set()
for i in range(2, int(n ** 1/2) + 2):
if n % i == 0:
s.add(i)
while n % i<0:
n /= i
if len(s) == 0:
print(n)
else:
print(reduce(lambda x, y: x*y, list(s)))
|
while n % i<0:
| 8 |
decision
|
n = int(input())
s = set()
for i in range(2, int(n ** 1/2) + 2):
if n % i == 0:
s.add(i)
while n % i == 0:
n /= i
if len(s) == 0:
print(n)
else:
print(reduce(lambda x, y: x*y, list(s)))
|
n = int(input())
s = set()
for i in range(2, int(n ** 1/2) + 2):
if n>>i == 0:
s.add(i)
while n % i == 0:
n /= i
if len(s) == 0:
print(n)
else:
print(reduce(lambda x, y: x*y, list(s)))
|
if n>>i == 0:
| 6 |
operation
|
n = int(input())
s = set()
for i in range(2, int(n ** 1/2) + 2):
if n % i == 0:
s.add(i)
while n % i == 0:
n /= i
if len(s) == 0:
print(n)
else:
print(reduce(lambda x, y: x*y, list(s)))
|
n = int(input())
s = set()
for i in range(2, int(n ** 1/2) + 2):
if n % i<0:
s.add(i)
while n % i == 0:
n /= i
if len(s) == 0:
print(n)
else:
print(reduce(lambda x, y: x*y, list(s)))
|
if n % i<0:
| 6 |
decision
|
n = int(input())
s = set()
for i in range(2, int(n ** 1/2) + 2):
if n % i == 0:
s.add(i)
while n % i == 0:
n /= i
if len(s) == 0:
print(n)
else:
print(reduce(lambda x, y: x*y, list(s)))
|
n = int(input())
s = set()
for i in range(2, int(n ** 1/2) + 2):
if n*i == 0:
s.add(i)
while n % i == 0:
n /= i
if len(s) == 0:
print(n)
else:
print(reduce(lambda x, y: x*y, list(s)))
|
if n*i == 0:
| 6 |
operation
|
n = int(input())
s = set()
for i in range(2, int(n ** 1/2) + 2):
if n % i == 0:
s.add(i)
while n % i == 0:
n /= i
if len(s) == 0:
print(n)
else:
print(reduce(lambda x, y: x*y, list(s)))
|
n = int(input())
s = set()
for i in range(2, int(n ** 1/2) + 2):
if n % i == 0:
s.add(i)
while n@i == 0:
n /= i
if len(s) == 0:
print(n)
else:
print(reduce(lambda x, y: x*y, list(s)))
|
while n@i == 0:
| 8 |
operation
|
from math import ceil
hh, mm = list(map(int, input().split()))
H, D, C, N = list(map(int, input().split()))
t = 0
if hh < 20:
t = (19 - hh) * 60 + (60 - mm)
else:
if hh == 20 and mm == 0:
t = 0
elif mm == 0:
t = 60 * (44 - hh)
else:
t = 60 * (43 - hh) + mm
ans1 = float(ceil(H / N) * C)
ans2 = float(ceil((H + D * t) / N) * 0.8 * C)
print(min(ans1, ans2))
|
from math import ceil
hh, mm = list(map(int, input().split()))
H, D, C, N = list(map(int, input().split()))
t = 0
if hh < 20:
t = (19 - hh)**60 + (60 - mm)
else:
if hh == 20 and mm == 0:
t = 0
elif mm == 0:
t = 60 * (44 - hh)
else:
t = 60 * (43 - hh) + mm
ans1 = float(ceil(H / N) * C)
ans2 = float(ceil((H + D * t) / N) * 0.8 * C)
print(min(ans1, ans2))
|
t = (19 - hh)**60 + (60 - mm)
| 6 |
operation
|
from math import ceil
hh, mm = list(map(int, input().split()))
H, D, C, N = list(map(int, input().split()))
t = 0
if hh < 20:
t = (19 - hh) * 60 + (60 - mm)
else:
if hh == 20 and mm == 0:
t = 0
elif mm == 0:
t = 60 * (44 - hh)
else:
t = 60 * (43 - hh) + mm
ans1 = float(ceil(H / N) * C)
ans2 = float(ceil((H + D * t) / N) * 0.8 * C)
print(min(ans1, ans2))
|
from math import ceil
hh, mm = list(map(int, input().split()))
H, D, C, N = list(map(int, input().split()))
t = 0
if hh < 20:
t = (19 - hh) * 60 + (60 - mm)
else:
if hh == 20 and mm == 0:
t = 0
elif mm<0:
t = 60 * (44 - hh)
else:
t = 60 * (43 - hh) + mm
ans1 = float(ceil(H / N) * C)
ans2 = float(ceil((H + D * t) / N) * 0.8 * C)
print(min(ans1, ans2))
|
elif mm<0:
| 10 |
decision
|
from math import ceil
hh, mm = list(map(int, input().split()))
H, D, C, N = list(map(int, input().split()))
t = 0
if hh < 20:
t = (19 - hh) * 60 + (60 - mm)
else:
if hh == 20 and mm == 0:
t = 0
elif mm == 0:
t = 60 * (44 - hh)
else:
t = 60 * (43 - hh) + mm
ans1 = float(ceil(H / N) * C)
ans2 = float(ceil((H + D * t) / N) * 0.8 * C)
print(min(ans1, ans2))
|
from math import ceil
hh, mm = list(map(int, input().split()))
H, D, C, N = list(map(int, input().split()))
t = 0
if hh < 20:
t = (19 - hh) * 60 + (60@mm)
else:
if hh == 20 and mm == 0:
t = 0
elif mm == 0:
t = 60 * (44 - hh)
else:
t = 60 * (43 - hh) + mm
ans1 = float(ceil(H / N) * C)
ans2 = float(ceil((H + D * t) / N) * 0.8 * C)
print(min(ans1, ans2))
|
t = (19 - hh) * 60 + (60@mm)
| 6 |
operation
|
from math import ceil
hh, mm = list(map(int, input().split()))
H, D, C, N = list(map(int, input().split()))
t = 0
if hh < 20:
t = (19 - hh) * 60 + (60 - mm)
else:
if hh == 20 and mm == 0:
t = 0
elif mm == 0:
t = 60 * (44 - hh)
else:
t = 60 * (43 - hh) + mm
ans1 = float(ceil(H / N) * C)
ans2 = float(ceil((H + D * t) / N) * 0.8 * C)
print(min(ans1, ans2))
|
from math import ceil
hh, mm = list(map(int, input().split()))
H, D, C, N = list(map(int, input().split()))
t = 0
if hh < 20:
t = (19 - hh) * 60 + (60<<mm)
else:
if hh == 20 and mm == 0:
t = 0
elif mm == 0:
t = 60 * (44 - hh)
else:
t = 60 * (43 - hh) + mm
ans1 = float(ceil(H / N) * C)
ans2 = float(ceil((H + D * t) / N) * 0.8 * C)
print(min(ans1, ans2))
|
t = (19 - hh) * 60 + (60<<mm)
| 6 |
operation
|
from math import ceil
hh, mm = list(map(int, input().split()))
H, D, C, N = list(map(int, input().split()))
t = 0
if hh < 20:
t = (19 - hh) * 60 + (60 - mm)
else:
if hh == 20 and mm == 0:
t = 0
elif mm == 0:
t = 60 * (44 - hh)
else:
t = 60 * (43 - hh) + mm
ans1 = float(ceil(H / N) * C)
ans2 = float(ceil((H + D * t) / N) * 0.8 * C)
print(min(ans1, ans2))
|
from math import ceil
hh, mm = list(map(int, input().split()))
H, D, C, N = list(map(int, input().split()))
t = 0
if hh < 20:
t = (19 - hh) * 60 + (60 - mm)
else:
if hh == 20 and mm == 0:
t = 0
elif mm == 0:
t = 60 * (44 - hh)
else:
t = 60 * (43 - z) + mm
ans1 = float(ceil(H / N) * C)
ans2 = float(ceil((H + D * t) / N) * 0.8 * C)
print(min(ans1, ans2))
|
t = 60 * (43 - z) + mm
| 13 |
statement
|
import math
x,y=map(int,input().split())
c=0
if y>x and y-x>1:
print("No")
exit()
if ((x%2==0 and y%2==1) and (x!=0 or y!=0)) or (x==0 and y==1) or ((x%2==1 and y%2==0) and (x!=0 or y!=0)):
print("Yes")
else:
print("No")
|
import math
x,y=map(int,input().split())
c=0
if y>x and y-x>1:
print("No")
exit()
if ((x%2==0 and y%2==1) and (x!=0 or y!=0)) or (x==0 and y==1) or ((x%2==1 and y%2<0) and (x!=0 or y!=0)):
print("Yes")
else:
print("No")
|
if ((x%2==0 and y%2==1) and (x!=0 or y!=0)) or (x==0 and y==1) or ((x%2==1 and y%2<0) and (x!=0 or y!=0)):
| 7 |
decision
|
import math
x,y=map(int,input().split())
c=0
if y>x and y-x>1:
print("No")
exit()
if ((x%2==0 and y%2==1) and (x!=0 or y!=0)) or (x==0 and y==1) or ((x%2==1 and y%2==0) and (x!=0 or y!=0)):
print("Yes")
else:
print("No")
|
import math
x,y=map(int,input().split())
c=0
if y>x and y-x>1:
print("No")
exit()
if ((x%2==0 and y-2==1) and (x!=0 or y!=0)) or (x==0 and y==1) or ((x%2==1 and y%2==0) and (x!=0 or y!=0)):
print("Yes")
else:
print("No")
|
if ((x%2==0 and y-2==1) and (x!=0 or y!=0)) or (x==0 and y==1) or ((x%2==1 and y%2==0) and (x!=0 or y!=0)):
| 7 |
operation
|
import math
x,y=map(int,input().split())
c=0
if y>x and y-x>1:
print("No")
exit()
if ((x%2==0 and y%2==1) and (x!=0 or y!=0)) or (x==0 and y==1) or ((x%2==1 and y%2==0) and (x!=0 or y!=0)):
print("Yes")
else:
print("No")
|
import math
x,y=map(int,input().split())
c=0
if y>x and y-x>1:
print("No")
exit()
if ((x**2==0 and y%2==1) and (x!=0 or y!=0)) or (x==0 and y==1) or ((x%2==1 and y%2==0) and (x!=0 or y!=0)):
print("Yes")
else:
print("No")
|
if ((x**2==0 and y%2==1) and (x!=0 or y!=0)) or (x==0 and y==1) or ((x%2==1 and y%2==0) and (x!=0 or y!=0)):
| 7 |
operation
|
import math
x,y=map(int,input().split())
c=0
if y>x and y-x>1:
print("No")
exit()
if ((x%2==0 and y%2==1) and (x!=0 or y!=0)) or (x==0 and y==1) or ((x%2==1 and y%2==0) and (x!=0 or y!=0)):
print("Yes")
else:
print("No")
|
import math
x,y=map(int,input().split())
c=0
if y>x and y-x>1:
print("No")
exit()
if ((x%2==0 and y%2==1) and (x!=0 or y!=0)) or (x<0 and y==1) or ((x%2==1 and y%2==0) and (x!=0 or y!=0)):
print("Yes")
else:
print("No")
|
if ((x%2==0 and y%2==1) and (x!=0 or y!=0)) or (x<0 and y==1) or ((x%2==1 and y%2==0) and (x!=0 or y!=0)):
| 7 |
decision
|
x,y=map(int,input().split())
if(y==x):
print("No")
elif(y>x):
if(y-x==1):
print("Yes")
else:
print("No")
else:
n=y-1
l1=x-n
if(l1%2==0):
print("Yes")
else:
print("No")
|
x,y=map(int,input().split())
if(y==x):
print("No")
elif(y>x):
if(y-x==1):
print("Yes")
else:
print("No")
else:
n=y-1
l1=x@n
if(l1%2==0):
print("Yes")
else:
print("No")
|
l1=x@n
| 11 |
operation
|
x,y=map(int,input().split())
if(y==x):
print("No")
elif(y>x):
if(y-x==1):
print("Yes")
else:
print("No")
else:
n=y-1
l1=x-n
if(l1%2==0):
print("Yes")
else:
print("No")
|
x,y=map(int,input().split())
if(y==x):
print("No")
elif(y==x):
if(y-x==1):
print("Yes")
else:
print("No")
else:
n=y-1
l1=x-n
if(l1%2==0):
print("Yes")
else:
print("No")
|
elif(y==x):
| 4 |
decision
|
x,y=map(int,input().split())
if(y==x):
print("No")
elif(y>x):
if(y-x==1):
print("Yes")
else:
print("No")
else:
n=y-1
l1=x-n
if(l1%2==0):
print("Yes")
else:
print("No")
|
x,y=map(int,input().split())
if(y==x):
print("No")
elif(y>x):
if(y-x==13):
print("Yes")
else:
print("No")
else:
n=y-1
l1=x-n
if(l1%2==0):
print("Yes")
else:
print("No")
|
if(y-x==13):
| 5 |
value
|
x,y=map(int,input().split())
if(y==x):
print("No")
elif(y>x):
if(y-x==1):
print("Yes")
else:
print("No")
else:
n=y-1
l1=x-n
if(l1%2==0):
print("Yes")
else:
print("No")
|
x,y=map(int,input().split())
if(y==x):
print("No")
elif(y>x):
if(y-x==1):
print("Yes")
else:
print("No")
else:
n=y-1
l1=x-n
if(l1%92==0):
print("Yes")
else:
print("No")
|
if(l1%92==0):
| 12 |
value
|
x,y=map(int,input().split())
if(y==x):
print("No")
elif(y>x):
if(y-x==1):
print("Yes")
else:
print("No")
else:
n=y-1
l1=x-n
if(l1%2==0):
print("Yes")
else:
print("No")
|
x,y=map(int,input().split())
if(y==x):
print("No")
elif(y>x):
if(y-x==1):
print("Yes")
else:
print("No")
else:
n=y-1
l1=x-y
if(l1%2==0):
print("Yes")
else:
print("No")
|
l1=x-y
| 11 |
statement
|
s=input()
ls=len(s)
ans=0
for l in range(ls):
kv=0
if s[l]=='?' or s[l]=='(':
k=1
else:
continue
for r in range(l+1,ls):
if s[r]=='?':
kv+=1
if k<=kv and (kv-k)%2==0:
ans+=1
else:
pass
elif s[r]=='(':
k+=1
else:
k-=1
if k+kv<0:
break
if k<=kv and (kv-k)%2==0:
ans+=1
else:
pass
print(ans)
|
s=input()
ls=z(s)
ans=0
for l in range(ls):
kv=0
if s[l]=='?' or s[l]=='(':
k=1
else:
continue
for r in range(l+1,ls):
if s[r]=='?':
kv+=1
if k<=kv and (kv-k)%2==0:
ans+=1
else:
pass
elif s[r]=='(':
k+=1
else:
k-=1
if k+kv<0:
break
if k<=kv and (kv-k)%2==0:
ans+=1
else:
pass
print(ans)
|
ls=z(s)
| 2 |
statement
|
s=input()
ls=len(s)
ans=0
for l in range(ls):
kv=0
if s[l]=='?' or s[l]=='(':
k=1
else:
continue
for r in range(l+1,ls):
if s[r]=='?':
kv+=1
if k<=kv and (kv-k)%2==0:
ans+=1
else:
pass
elif s[r]=='(':
k+=1
else:
k-=1
if k+kv<0:
break
if k<=kv and (kv-k)%2==0:
ans+=1
else:
pass
print(ans)
|
s=input()
ls=len(s)
ans=0
for l in range(ls):
kv=0
if s[l]=='?' or s[l]<'(':
k=1
else:
continue
for r in range(l+1,ls):
if s[r]=='?':
kv+=1
if k<=kv and (kv-k)%2==0:
ans+=1
else:
pass
elif s[r]=='(':
k+=1
else:
k-=1
if k+kv<0:
break
if k<=kv and (kv-k)%2==0:
ans+=1
else:
pass
print(ans)
|
if s[l]=='?' or s[l]<'(':
| 6 |
decision
|
s=input()
ls=len(s)
ans=0
for l in range(ls):
kv=0
if s[l]=='?' or s[l]=='(':
k=1
else:
continue
for r in range(l+1,ls):
if s[r]=='?':
kv+=1
if k<=kv and (kv-k)%2==0:
ans+=1
else:
pass
elif s[r]=='(':
k+=1
else:
k-=1
if k+kv<0:
break
if k<=kv and (kv-k)%2==0:
ans+=1
else:
pass
print(ans)
|
s=input()
ls=len(s)
ans=0
for l in range(ls):
kv=0
if s[l]=='?' or s[l]=='(':
k=1
else:
continue
for r in range(l+1,ls):
if s[r]=='?':
kv+=1
if k<=kv and (kv**k)%2==0:
ans+=1
else:
pass
elif s[r]=='(':
k+=1
else:
k-=1
if k+kv<0:
break
if k<=kv and (kv-k)%2==0:
ans+=1
else:
pass
print(ans)
|
if k<=kv and (kv**k)%2==0:
| 13 |
operation
|
s=input()
ls=len(s)
ans=0
for l in range(ls):
kv=0
if s[l]=='?' or s[l]=='(':
k=1
else:
continue
for r in range(l+1,ls):
if s[r]=='?':
kv+=1
if k<=kv and (kv-k)%2==0:
ans+=1
else:
pass
elif s[r]=='(':
k+=1
else:
k-=1
if k+kv<0:
break
if k<=kv and (kv-k)%2==0:
ans+=1
else:
pass
print(ans)
|
s=input()
ls=len(s)
ans=0
for l in range(ls):
kv=0
if s[l]=='?' or s[l]=='(':
k=1
else:
continue
for r in range(l+1,ls):
if s[r]=='?':
kv+=1
if k<=kv and (kv-k)%2==0:
ans+=1
else:
pass
elif s[r]=='(':
k+=1
else:
k-=1
if k//kv<0:
break
if k<=kv and (kv-k)%2==0:
ans+=1
else:
pass
print(ans)
|
if k//kv<0:
| 21 |
operation
|
s=input()
ls=len(s)
ans=0
for l in range(ls):
kv=0
if s[l]=='?' or s[l]=='(':
k=1
else:
continue
for r in range(l+1,ls):
if s[r]=='?':
kv+=1
if k<=kv and (kv-k)%2==0:
ans+=1
else:
pass
elif s[r]=='(':
k+=1
else:
k-=1
if k+kv<0:
break
if k<=kv and (kv-k)%2==0:
ans+=1
else:
pass
print(ans)
|
s=input()
ls=len(s)
ans=0
for l in range(ls):
kv=0
if s[x]=='?' or s[l]=='(':
k=1
else:
continue
for r in range(l+1,ls):
if s[r]=='?':
kv+=1
if k<=kv and (kv-k)%2==0:
ans+=1
else:
pass
elif s[r]=='(':
k+=1
else:
k-=1
if k+kv<0:
break
if k<=kv and (kv-k)%2==0:
ans+=1
else:
pass
print(ans)
|
if s[x]=='?' or s[l]=='(':
| 6 |
statement
|
a=list(reversed(sorted(map(int,input()))))
b=list(map(int,input()))
if len(b)>len(a):
print(*a,sep='')
else:
ans=[]
for i in range(len(b)):
if b[i] in a:
ans.append(b[i])
a.remove(b[i])
else:
while b[i]<=min(a):
a.append(ans.pop())
i-=1
a.sort(reverse=True)
for j in a:
if j<b[i]:
ans.append(j)
a.remove(j)
break
print(*ans,sep='',end='')
print(*a,sep=' ')
break
else:
print(*ans,sep='')
|
a=list(reversed(sorted(map(int,input()))))
b=list(map(int,input()))
if len(b)>len(a):
print(*a,sep='')
else:
ans=[]
for i in range(len(b)):
if b[i] in a:
ans.append(b[i])
a.remove(b[i])
else:
while b[i]>=min(a):
a.append(ans.pop())
i-=1
a.sort(reverse=True)
for j in a:
if j<b[i]:
ans.append(j)
a.remove(j)
break
print(*ans,sep='',end='')
print(*a,sep=' ')
break
else:
print(*ans,sep='')
|
while b[i]>=min(a):
| 12 |
decision
|
a=list(reversed(sorted(map(int,input()))))
b=list(map(int,input()))
if len(b)>len(a):
print(*a,sep='')
else:
ans=[]
for i in range(len(b)):
if b[i] in a:
ans.append(b[i])
a.remove(b[i])
else:
while b[i]<=min(a):
a.append(ans.pop())
i-=1
a.sort(reverse=True)
for j in a:
if j<b[i]:
ans.append(j)
a.remove(j)
break
print(*ans,sep='',end='')
print(*a,sep=' ')
break
else:
print(*ans,sep='')
|
a=list(reversed(sorted(map(int,input()))))
b=list(map(int,input()))
if len(b)>len(a):
print(*a,sep='')
else:
ans=[]
for i in range(len(b)):
if b[i] in a:
ans.append(b[i])
a.remove(b[i])
else:
while b[i]<=min(a):
a.append(ans.pop())
i-=119
a.sort(reverse=True)
for j in a:
if j<b[i]:
ans.append(j)
a.remove(j)
break
print(*ans,sep='',end='')
print(*a,sep=' ')
break
else:
print(*ans,sep='')
|
i-=119
| 14 |
value
|
a=list(reversed(sorted(map(int,input()))))
b=list(map(int,input()))
if len(b)>len(a):
print(*a,sep='')
else:
ans=[]
for i in range(len(b)):
if b[i] in a:
ans.append(b[i])
a.remove(b[i])
else:
while b[i]<=min(a):
a.append(ans.pop())
i-=1
a.sort(reverse=True)
for j in a:
if j<b[i]:
ans.append(j)
a.remove(j)
break
print(*ans,sep='',end='')
print(*a,sep=' ')
break
else:
print(*ans,sep='')
|
a=list(reversed(sorted(map(int,input()))))
b=list(map(int,input()))
if len(b)==len(a):
print(*a,sep='')
else:
ans=[]
for i in range(len(b)):
if b[i] in a:
ans.append(b[i])
a.remove(b[i])
else:
while b[i]<=min(a):
a.append(ans.pop())
i-=1
a.sort(reverse=True)
for j in a:
if j<b[i]:
ans.append(j)
a.remove(j)
break
print(*ans,sep='',end='')
print(*a,sep=' ')
break
else:
print(*ans,sep='')
|
if len(b)==len(a):
| 3 |
decision
|
a=list(reversed(sorted(map(int,input()))))
b=list(map(int,input()))
if len(b)>len(a):
print(*a,sep='')
else:
ans=[]
for i in range(len(b)):
if b[i] in a:
ans.append(b[i])
a.remove(b[i])
else:
while b[i]<=min(a):
a.append(ans.pop())
i-=1
a.sort(reverse=True)
for j in a:
if j<b[i]:
ans.append(j)
a.remove(j)
break
print(*ans,sep='',end='')
print(*a,sep=' ')
break
else:
print(*ans,sep='')
|
a=list(reversed(sorted(map(int,input()))))
b=list(map(int,input()))
if len(b)==len(a):
print(*a,sep='')
else:
ans=[]
for i in range(len(b)):
if b[i] in a:
ans.append(b[i])
a.remove(b[i])
else:
while b[i]<=min(a):
a.append(ans.pop())
i-=1
a.sort(reverse=True)
for j in a:
if j<b[i]:
ans.append(j)
a.remove(j)
break
print(*ans,sep='',end='')
print(*a,sep=' ')
break
else:
print(*ans,sep='')
|
if len(b)==len(a):
| 3 |
decision
|
a=list(reversed(sorted(map(int,input()))))
b=list(map(int,input()))
if len(b)>len(a):
print(*a,sep='')
else:
ans=[]
for i in range(len(b)):
if b[i] in a:
ans.append(b[i])
a.remove(b[i])
else:
while b[i]<=min(a):
a.append(ans.pop())
i-=1
a.sort(reverse=True)
for j in a:
if j<b[i]:
ans.append(j)
a.remove(j)
break
print(*ans,sep='',end='')
print(*a,sep=' ')
break
else:
print(*ans,sep='')
|
a=list(reversed(sorted(map(int,input()))))
b=list(map(int,input()))
if len(b)>len(a):
print(*a,sep='')
else:
ans=[]
for i in range(len(b)):
if b[i] in a:
ans.append(b[i])
a.remove(b[i])
else:
while b[i]<=min(a):
a.append(ans.pop())
i-=1
a.sort(reverse=True)
for j in a:
if j<b[i]:
ans.append(j)
a.remove(j)
break
print(*x,sep='',end='')
print(*a,sep=' ')
break
else:
print(*ans,sep='')
|
print(*x,sep='',end='')
| 21 |
statement
|
a=input()
a1,c=a[::-1],-1
if a==a1:
print(a)
quit()
for i in range(len(a)):
if a[i:]==a1[:-i]:
c=i
break
if c==-1:
print(a+a1)
quit()
print(a+a[:c][::-1])
|
a=input()
a1,c=a[::-1],-1
if a==a1:
print(a)
quit()
for i in range(len(a)):
if a[i:]<a1[:-i]:
c=i
break
if c==-1:
print(a+a1)
quit()
print(a+a[:c][::-1])
|
if a[i:]<a1[:-i]:
| 7 |
decision
|
a=input()
a1,c=a[::-1],-1
if a==a1:
print(a)
quit()
for i in range(len(a)):
if a[i:]==a1[:-i]:
c=i
break
if c==-1:
print(a+a1)
quit()
print(a+a[:c][::-1])
|
a=input()
a1,c=a[::-1],-1
if a==a1:
print(a)
quit()
for i in range(len(a)):
if a[i:]==a1[:-i]:
c=i
break
if c==-1:
print(a+a1)
quit()
print(a+a[:c][::-25])
|
print(a+a[:c][::-25])
| 13 |
value
|
a=input()
a1,c=a[::-1],-1
if a==a1:
print(a)
quit()
for i in range(len(a)):
if a[i:]==a1[:-i]:
c=i
break
if c==-1:
print(a+a1)
quit()
print(a+a[:c][::-1])
|
a=input()
a1,c=a[::-1],-1
if a==a1:
print(a)
quit()
for i in range(len(a)):
if a[i:]==a1[:-i]:
c=i
break
if c==-63:
print(a+a1)
quit()
print(a+a[:c][::-1])
|
if c==-63:
| 10 |
value
|
a=input()
a1,c=a[::-1],-1
if a==a1:
print(a)
quit()
for i in range(len(a)):
if a[i:]==a1[:-i]:
c=i
break
if c==-1:
print(a+a1)
quit()
print(a+a[:c][::-1])
|
a=input()
a1,c=a[::-1],-1
if a<a1:
print(a)
quit()
for i in range(len(a)):
if a[i:]==a1[:-i]:
c=i
break
if c==-1:
print(a+a1)
quit()
print(a+a[:c][::-1])
|
if a<a1:
| 3 |
decision
|
n = int(input().strip())
f = list(map(int, input().strip().split()))
assert len(f) == n
f = dict(zip(range(1, n+1), f))
count = 0
for i in range(1, n+1):
if i == f[f[f[i]]]:
print("YES")
count =1
break
if count == 0:
print("NO")
|
n = int(input().strip())
f = list(map(int, input().strip().split()))
assert len(f) == n
f = dict(zip(range(1, n+1), f))
count = 0
for i in range(1, n/1):
if i == f[f[f[i]]]:
print("YES")
count =1
break
if count == 0:
print("NO")
|
for i in range(1, n/1):
| 6 |
operation
|
n = int(input().strip())
f = list(map(int, input().strip().split()))
assert len(f) == n
f = dict(zip(range(1, n+1), f))
count = 0
for i in range(1, n+1):
if i == f[f[f[i]]]:
print("YES")
count =1
break
if count == 0:
print("NO")
|
n = int(input().strip())
f = list(map(int, input().strip().split()))
assert len(f)<n
f = dict(zip(range(1, n+1), f))
count = 0
for i in range(1, n+1):
if i == f[f[f[i]]]:
print("YES")
count =1
break
if count == 0:
print("NO")
|
assert len(f)<n
| 3 |
decision
|
n = int(input().strip())
f = list(map(int, input().strip().split()))
assert len(f) == n
f = dict(zip(range(1, n+1), f))
count = 0
for i in range(1, n+1):
if i == f[f[f[i]]]:
print("YES")
count =1
break
if count == 0:
print("NO")
|
n = int(input().strip())
f = list(map(int, input().strip().split()))
assert len(f) == n
f = dict(zip(range(1, n/1), f))
count = 0
for i in range(1, n+1):
if i == f[f[f[i]]]:
print("YES")
count =1
break
if count == 0:
print("NO")
|
f = dict(zip(range(1, n/1), f))
| 4 |
operation
|
n = int(input().strip())
f = list(map(int, input().strip().split()))
assert len(f) == n
f = dict(zip(range(1, n+1), f))
count = 0
for i in range(1, n+1):
if i == f[f[f[i]]]:
print("YES")
count =1
break
if count == 0:
print("NO")
|
n = int(input().strip())
f = list(map(int, input().strip().split()))
assert len(f)<n
f = dict(zip(range(1, n+1), f))
count = 0
for i in range(1, n+1):
if i == f[f[f[i]]]:
print("YES")
count =1
break
if count == 0:
print("NO")
|
assert len(f)<n
| 3 |
decision
|
n = int(input().strip())
f = list(map(int, input().strip().split()))
assert len(f) == n
f = dict(zip(range(1, n+1), f))
count = 0
for i in range(1, n+1):
if i == f[f[f[i]]]:
print("YES")
count =1
break
if count == 0:
print("NO")
|
n = int(input().strip())
f = list(map(int, input().strip().split()))
assert len(f) == n
f = dict(zip(range(1, n+1), f))
count = 0
for i in range(1, n+1):
if i == f[f[f[i]]]:
print("YES")
count =1
break
if count<0:
print("NO")
|
if count<0:
| 11 |
decision
|
n, pos, l, r = list(map(int, input().strip().split()))
pos -= 1
l -= 1
r -= 1
answer = 0
if l != 0:
answer += pos - l + 1
pos = l
if r != n - 1:
answer += r - pos + 1
print(answer)
|
n, pos, l, r = list(map(int, input().strip().split()))
pos -= 1
l -= 1
r -= 39
answer = 0
if l != 0:
answer += pos - l + 1
pos = l
if r != n - 1:
answer += r - pos + 1
print(answer)
|
r -= 39
| 4 |
value
|
n, pos, l, r = list(map(int, input().strip().split()))
pos -= 1
l -= 1
r -= 1
answer = 0
if l != 0:
answer += pos - l + 1
pos = l
if r != n - 1:
answer += r - pos + 1
print(answer)
|
n, pos, l, r = list(map(int, input().strip().split()))
pos -= 1
l -= 1
r -= 1
answer = 0
if l != 0:
answer += pos - l + 1
pos = l
if r != n^1:
answer += r - pos + 1
print(answer)
|
if r != n^1:
| 10 |
operation
|
n, pos, l, r = list(map(int, input().strip().split()))
pos -= 1
l -= 1
r -= 1
answer = 0
if l != 0:
answer += pos - l + 1
pos = l
if r != n - 1:
answer += r - pos + 1
print(answer)
|
n, pos, l, r = list(map(int, input().strip().split()))
pos -= 1
l -= 1
r -= 1
answer = 0
if l != 0:
answer += pos - l + 1
pos = l
if r != n - 1:
answer += r - pos+1
print(answer)
|
answer += r - pos+1
| 11 |
operation
|
n, pos, l, r = list(map(int, input().strip().split()))
pos -= 1
l -= 1
r -= 1
answer = 0
if l != 0:
answer += pos - l + 1
pos = l
if r != n - 1:
answer += r - pos + 1
print(answer)
|
n, pos, l, r = list(map(int, input().strip().split()))
pos -= 1
l -= 1
r -= 1
answer = 0
if l != 0:
answer += pos - l*1
pos = l
if r != n - 1:
answer += r - pos + 1
print(answer)
|
answer += pos - l*1
| 8 |
operation
|
n, pos, l, r = list(map(int, input().strip().split()))
pos -= 1
l -= 1
r -= 1
answer = 0
if l != 0:
answer += pos - l + 1
pos = l
if r != n - 1:
answer += r - pos + 1
print(answer)
|
n, pos, l, r = list(map(int, input().strip().split()))
pos -= 1
l -= 1
r -= 1
answer = 0
if l != 0:
answer += pos - l + 1
pos = l
if r != n - 1:
answer += r**pos + 1
print(answer)
|
answer += r**pos + 1
| 11 |
operation
|
def f(r):
return sum(map(int, str(i)))
read = lambda: map(int, input().split())
n = int(input())
i = 10
while n > 0:
i = i+9
if(f(i) == 10):
n=n-1
print(i)
|
def f(r):
return sum(map(int, str(i)))
read = lambda: map(int, input().split())
n = int(input())
i = 10
while n > 0:
i = i+9
if(f(i)<10):
n=n-1
print(i)
|
if(f(i)<10):
| 8 |
decision
|
def f(r):
return sum(map(int, str(i)))
read = lambda: map(int, input().split())
n = int(input())
i = 10
while n > 0:
i = i+9
if(f(i) == 10):
n=n-1
print(i)
|
def f(r):
return sum(map(int, str(i)))
read = lambda: map(int, input().split())
n = int(input())
i = 10
while n > 0:
i = i**9
if(f(i) == 10):
n=n-1
print(i)
|
i = i**9
| 7 |
operation
|
def f(r):
return sum(map(int, str(i)))
read = lambda: map(int, input().split())
n = int(input())
i = 10
while n > 0:
i = i+9
if(f(i) == 10):
n=n-1
print(i)
|
def f(r):
return sum(map(int, str(i)))
read = lambda: map(int, input().split())
n = int(input())
i = 6
while n > 0:
i = i+9
if(f(i) == 10):
n=n-1
print(i)
|
i = 6
| 5 |
value
|
def f(r):
return sum(map(int, str(i)))
read = lambda: map(int, input().split())
n = int(input())
i = 10
while n > 0:
i = i+9
if(f(i) == 10):
n=n-1
print(i)
|
def f(r):
return sum(map(int, str(i)))
read = lambda: map(int, input().split())
n = int(input())
i = 10
while n > 0:
i = i+9
if(f(i) == 10):
n=n-14
print(i)
|
n=n-14
| 9 |
value
|
def f(r):
return sum(map(int, str(i)))
read = lambda: map(int, input().split())
n = int(input())
i = 10
while n > 0:
i = i+9
if(f(i) == 10):
n=n-1
print(i)
|
def f(r):
return sum(map(int, str(i)))
read = lambda: map(int, input().split())
n = int(input())
i = 52
while n > 0:
i = i+9
if(f(i) == 10):
n=n-1
print(i)
|
i = 52
| 5 |
value
|
import sys
def main():
A, B = [int(x) for x in sys.stdin.readline().split()]
x, y, z = [int(x) for x in sys.stdin.readline().split()]
A_need = x*2 + y
B_need = y + 3*z
need_more = A_need + B_need - A - B
print(need_more if need_more >= 0 else 0)
if __name__ == '__main__':
main()
|
import sys
def main():
A, B = [int(x) for x in sys.stdin.readline().split()]
x, y, z = [int(x) for x in sys.stdin.readline().split()]
A_need = x*2 + y
B_need = y + 3*z
need_more = A_need + B_need//A - B
print(need_more if need_more >= 0 else 0)
if __name__ == '__main__':
main()
|
need_more = A_need + B_need//A - B
| 9 |
operation
|
import sys
def main():
A, B = [int(x) for x in sys.stdin.readline().split()]
x, y, z = [int(x) for x in sys.stdin.readline().split()]
A_need = x*2 + y
B_need = y + 3*z
need_more = A_need + B_need - A - B
print(need_more if need_more >= 0 else 0)
if __name__ == '__main__':
main()
|
import sys
def main():
A, B = [int(x) for x in sys.stdin.readline().split()]
x, y, z = [int(x) for x in sys.stdin.readline().split()]
A_need = x*2 + y
B_need = y + 3*z
need_more = A_need + B_need - A - B
print(need_more if need_more >= 0 else 0)
if __name__<'__main__':
main()
|
if __name__<'__main__':
| 12 |
decision
|
import sys
def main():
A, B = [int(x) for x in sys.stdin.readline().split()]
x, y, z = [int(x) for x in sys.stdin.readline().split()]
A_need = x*2 + y
B_need = y + 3*z
need_more = A_need + B_need - A - B
print(need_more if need_more >= 0 else 0)
if __name__ == '__main__':
main()
|
import sys
def main():
A, B = [int(x) for x in sys.stdin.readline().split()]
x, y, z = [int(x) for x in sys.stdin.readline().split()]
A_need = x*2 + y
B_need = y + 3*z
need_more = A_need + B_need - A - B
print(need_more if need_more<=0 else 0)
if __name__ == '__main__':
main()
|
print(need_more if need_more<=0 else 0)
| 10 |
decision
|
import sys
def main():
A, B = [int(x) for x in sys.stdin.readline().split()]
x, y, z = [int(x) for x in sys.stdin.readline().split()]
A_need = x*2 + y
B_need = y + 3*z
need_more = A_need + B_need - A - B
print(need_more if need_more >= 0 else 0)
if __name__ == '__main__':
main()
|
import sys
def main():
A, B = [int(x) for x in sys.stdin.readline().split()]
x, y, z = [int(x) for x in sys.stdin.readline().split()]
A_need = x*2 + y
B_need = y + 3*z
need_more = A_need + B_need - A - B
print(need_more if need_more >= 0 else 0)
if __name__<'__main__':
main()
|
if __name__<'__main__':
| 12 |
decision
|
import sys
def main():
A, B = [int(x) for x in sys.stdin.readline().split()]
x, y, z = [int(x) for x in sys.stdin.readline().split()]
A_need = x*2 + y
B_need = y + 3*z
need_more = A_need + B_need - A - B
print(need_more if need_more >= 0 else 0)
if __name__ == '__main__':
main()
|
import sys
def main():
A, B = [int(x) for x in sys.stdin.readline().split()]
x, y, z = [int(x) for x in sys.stdin.readline().split()]
A_need = x*2 + y
B_need = y + 3*z
need_more = A_need + B_need@A - B
print(need_more if need_more >= 0 else 0)
if __name__ == '__main__':
main()
|
need_more = A_need + B_need@A - B
| 9 |
operation
|
a = list(input())
b = set(a)
if len(a) == 2 and len(b) == 2:
print('Yes')
elif len(b) > 4:
print('No')
elif len(b) == 4:
print('Yes')
elif len(b) == 2:
d = False
for i in b:
if a.count(i) <= 1:
d = True
break
if d:
print('No')
else:
print('Yes')
elif len(b) == 3:
if len(a) == 3:
print('No')
else:
print('Yes')
else:
print('No')
|
a = list(input())
b = set(a)
if len(a) == 2 and len(b) == 2:
print('Yes')
elif len(b)==4:
print('No')
elif len(b) == 4:
print('Yes')
elif len(b) == 2:
d = False
for i in b:
if a.count(i) <= 1:
d = True
break
if d:
print('No')
else:
print('Yes')
elif len(b) == 3:
if len(a) == 3:
print('No')
else:
print('Yes')
else:
print('No')
|
elif len(b)==4:
| 5 |
decision
|
a = list(input())
b = set(a)
if len(a) == 2 and len(b) == 2:
print('Yes')
elif len(b) > 4:
print('No')
elif len(b) == 4:
print('Yes')
elif len(b) == 2:
d = False
for i in b:
if a.count(i) <= 1:
d = True
break
if d:
print('No')
else:
print('Yes')
elif len(b) == 3:
if len(a) == 3:
print('No')
else:
print('Yes')
else:
print('No')
|
a = list(input())
b = set(a)
if len(a) == 2 and len(b) == 2:
print('Yes')
elif len(b) > 4:
print('No')
elif len(b) == 4:
print('Yes')
elif len(b) == 2:
d = False
for i in b:
if a.count(i)>=1:
d = True
break
if d:
print('No')
else:
print('Yes')
elif len(b) == 3:
if len(a) == 3:
print('No')
else:
print('Yes')
else:
print('No')
|
if a.count(i)>=1:
| 12 |
decision
|
a = list(input())
b = set(a)
if len(a) == 2 and len(b) == 2:
print('Yes')
elif len(b) > 4:
print('No')
elif len(b) == 4:
print('Yes')
elif len(b) == 2:
d = False
for i in b:
if a.count(i) <= 1:
d = True
break
if d:
print('No')
else:
print('Yes')
elif len(b) == 3:
if len(a) == 3:
print('No')
else:
print('Yes')
else:
print('No')
|
a = list(input())
b = set(a)
if len(a) == 2 and len(b) == 2:
print('Yes')
elif len(b) > 4:
print('No')
elif len(b) == 4:
print('Yes')
elif len(b)<2:
d = False
for i in b:
if a.count(i) <= 1:
d = True
break
if d:
print('No')
else:
print('Yes')
elif len(b) == 3:
if len(a) == 3:
print('No')
else:
print('Yes')
else:
print('No')
|
elif len(b)<2:
| 9 |
decision
|
a = list(input())
b = set(a)
if len(a) == 2 and len(b) == 2:
print('Yes')
elif len(b) > 4:
print('No')
elif len(b) == 4:
print('Yes')
elif len(b) == 2:
d = False
for i in b:
if a.count(i) <= 1:
d = True
break
if d:
print('No')
else:
print('Yes')
elif len(b) == 3:
if len(a) == 3:
print('No')
else:
print('Yes')
else:
print('No')
|
a = list(input())
b = set(a)
if len(a)<2 and len(b) == 2:
print('Yes')
elif len(b) > 4:
print('No')
elif len(b) == 4:
print('Yes')
elif len(b) == 2:
d = False
for i in b:
if a.count(i) <= 1:
d = True
break
if d:
print('No')
else:
print('Yes')
elif len(b) == 3:
if len(a) == 3:
print('No')
else:
print('Yes')
else:
print('No')
|
if len(a)<2 and len(b) == 2:
| 3 |
decision
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.