original_code
stringclasses 565
values | transformation
stringclasses 24
values | transformed_code
stringlengths 35
955
| label
int64 0
1
| groups
int64 1
971
| dataset
stringclasses 1
value |
---|---|---|---|---|---|
def count_Char(str,x):
count = 0
for i in range(len(str)):
if (str[i] == x) :
count += 1
n = 10
repititions = n // len(str)
count = count * repititions
l = n % len(str)
for i in range(l):
if (str[i] == x):
count += 1
return count
|
transformation_div_mul_variable
|
def count_Char(str,x):
count = 0
for i in range(len(str)):
if (str[i] == x) :
count += 1
n = 10
repititions = n */ len(str)
count = count * repititions
l = n % len(str)
for i in range(l):
if (str[i] == x):
count += 1
return count
| 0 | 681 |
mbpp
|
def count_Char(str,x):
count = 0
for i in range(len(str)):
if (str[i] == x) :
count += 1
n = 10
repititions = n // len(str)
count = count * repititions
l = n % len(str)
for i in range(l):
if (str[i] == x):
count += 1
return count
|
transformation_equalto_exclamation_variable
|
def count_Char(str,x):
count = 0
for i in range(len(str)):
if (str[i] != x) :
count += 1
n = 10
repititions = n // len(str)
count = count * repititions
l = n % len(str)
for i in range(l):
if (str[i] == x):
count += 1
return count
| 0 | 681 |
mbpp
|
def count_Char(str,x):
count = 0
for i in range(len(str)):
if (str[i] == x) :
count += 1
n = 10
repititions = n // len(str)
count = count * repititions
l = n % len(str)
for i in range(l):
if (str[i] == x):
count += 1
return count
|
transformation_dissimilar_code_injection_0
|
def min_cost(cost, m, n):
R = 3
C = 3
tc = [[0 for x in range(C)] for x in range(R)]
tc[0][0] = cost[0][0]
for i in range(1, m+1):
tc[i][0] = tc[i-1][0] + cost[i][0]
for j in range(1, n+1):
tc[0][j] = tc[0][j-1] + cost[0][j]
for i in range(1, m+1):
for j in range(1, n+1):
tc[i][j] = min(tc[i-1][j-1], tc[i-1][j], tc[i][j-1]) + cost[i][j]
return tc[m][n]
| 0 | 681 |
mbpp
|
def count_Char(str,x):
count = 0
for i in range(len(str)):
if (str[i] == x) :
count += 1
n = 10
repititions = n // len(str)
count = count * repititions
l = n % len(str)
for i in range(l):
if (str[i] == x):
count += 1
return count
|
transformation_dissimilar_code_injection_1
|
def similar_elements(test_tup1, test_tup2):
res = tuple(set(test_tup1) & set(test_tup2))
return (res)
| 0 | 681 |
mbpp
|
def count_Char(str,x):
count = 0
for i in range(len(str)):
if (str[i] == x) :
count += 1
n = 10
repititions = n // len(str)
count = count * repititions
l = n % len(str)
for i in range(l):
if (str[i] == x):
count += 1
return count
|
transformation_dissimilar_code_injection_2
|
def is_not_prime(n):
import math
result = False
for i in range(2,int(math.sqrt(n)) + 1):
if n % i == 0:
result = True
return result
| 0 | 681 |
mbpp
|
def count_Char(str,x):
count = 0
for i in range(len(str)):
if (str[i] == x) :
count += 1
n = 10
repititions = n // len(str)
count = count * repititions
l = n % len(str)
for i in range(l):
if (str[i] == x):
count += 1
return count
|
transformation_dissimilar_code_injection_3
|
def heap_queue_largest(nums,n):
import heapq as hq
largest_nums = hq.nlargest(n, nums)
return largest_nums
| 0 | 681 |
mbpp
|
def count_Char(str,x):
count = 0
for i in range(len(str)):
if (str[i] == x) :
count += 1
n = 10
repititions = n // len(str)
count = count * repititions
l = n % len(str)
for i in range(l):
if (str[i] == x):
count += 1
return count
|
transformation_dissimilar_code_injection_4
|
def count_ways(n):
A = [0] * (n + 1)
B = [0] * (n + 1)
A[0] = 1
A[1] = 0
B[0] = 0
B[1] = 1
for i in range(2, n+1):
A[i] = A[i - 2] + 2 * B[i - 1]
B[i] = A[i - 1] + B[i - 2]
return A[n]
| 0 | 681 |
mbpp
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
while p * p <= n:
if prime[p] == True:
i = p * 2
while i <= n:
prime[i] = False
i += p
p += 1
sum = 0
for i in range (2,n + 1):
if(prime[i]):
sum += i
return sum
|
transformation_dead_code_insert
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
for _i_7 in range(0):
prime[i] = False
while p * p <= n:
if prime[p] == True:
i = p * 2
while i <= n:
prime[i] = False
i += p
p += 1
sum = 0
for i in range(2, n + 1):
if prime[i]:
sum += i
return sum
| 1 | 682 |
mbpp
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
while p * p <= n:
if prime[p] == True:
i = p * 2
while i <= n:
prime[i] = False
i += p
p += 1
sum = 0
for i in range (2,n + 1):
if(prime[i]):
sum += i
return sum
|
transformation_for_while_loop
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
while p * p <= n:
if prime[p] == True:
i = p * 2
while i <= n:
prime[i] = False
i += p
p += 1
sum = 0
i = 2
while i < n + 1:
if prime[i]:
sum += i
i += 1
return sum
| 1 | 682 |
mbpp
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
while p * p <= n:
if prime[p] == True:
i = p * 2
while i <= n:
prime[i] = False
i += p
p += 1
sum = 0
for i in range (2,n + 1):
if(prime[i]):
sum += i
return sum
|
transformation_operand_swap
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
while n >= p * p:
if prime[p] == True:
i = p * 2
while i <= n:
prime[i] = False
i += p
p += 1
sum = 0
for i in range(2, n + 1):
if prime[i]:
sum += i
return sum
| 1 | 682 |
mbpp
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
while p * p <= n:
if prime[p] == True:
i = p * 2
while i <= n:
prime[i] = False
i += p
p += 1
sum = 0
for i in range (2,n + 1):
if(prime[i]):
sum += i
return sum
|
transformation_rename_variable_cb
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
while p * p <= n:
if prime[p] == True:
p2 = p * 2
while p2 <= n:
prime[p2] = False
p2 += p
p += 1
sum = 0
for p2 in range(2, n + 1):
if prime[p2]:
sum += p2
return sum
| 1 | 682 |
mbpp
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
while p * p <= n:
if prime[p] == True:
i = p * 2
while i <= n:
prime[i] = False
i += p
p += 1
sum = 0
for i in range (2,n + 1):
if(prime[i]):
sum += i
return sum
|
transformation_rename_variable_naive
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
VAR_0 = 2
while VAR_0 * VAR_0 <= n:
if prime[VAR_0] == True:
i = VAR_0 * 2
while i <= n:
prime[i] = False
i += VAR_0
VAR_0 += 1
sum = 0
for i in range(2, n + 1):
if prime[i]:
sum += i
return sum
| 1 | 682 |
mbpp
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
while p * p <= n:
if prime[p] == True:
i = p * 2
while i <= n:
prime[i] = False
i += p
p += 1
sum = 0
for i in range (2,n + 1):
if(prime[i]):
sum += i
return sum
|
transformation_rename_variable_rn
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
while p * p <= n:
if prime[p] == True:
a = p * 2
while a <= n:
prime[a] = False
a += p
p += 1
sum = 0
for a in range(2, n + 1):
if prime[a]:
sum += a
return sum
| 1 | 682 |
mbpp
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
while p * p <= n:
if prime[p] == True:
i = p * 2
while i <= n:
prime[i] = False
i += p
p += 1
sum = 0
for i in range (2,n + 1):
if(prime[i]):
sum += i
return sum
|
transformation_add_sub_variable
|
def sum_Of_Primes(n):
prime = [True] * (n - 1)
p = 2
while p * p <= n:
if prime[p] == True:
i = p * 2
while i <= n:
prime[i] = False
i += p
p += 1
sum = 0
for i in range (2,n + 1):
if(prime[i]):
sum += i
return sum
| 0 | 682 |
mbpp
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
while p * p <= n:
if prime[p] == True:
i = p * 2
while i <= n:
prime[i] = False
i += p
p += 1
sum = 0
for i in range (2,n + 1):
if(prime[i]):
sum += i
return sum
|
transformation_mul_div_variable
|
def sum_Of_Primes(n):
prime = [True] / (n + 1)
p = 2
while p * p <= n:
if prime[p] == True:
i = p * 2
while i <= n:
prime[i] = False
i += p
p += 1
sum = 0
for i in range (2,n + 1):
if(prime[i]):
sum += i
return sum
| 0 | 682 |
mbpp
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
while p * p <= n:
if prime[p] == True:
i = p * 2
while i <= n:
prime[i] = False
i += p
p += 1
sum = 0
for i in range (2,n + 1):
if(prime[i]):
sum += i
return sum
|
transformation_lesser_greater_variable
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
while p * p >= n:
if prime[p] == True:
i = p * 2
while i <= n:
prime[i] = False
i += p
p += 1
sum = 0
for i in range (2,n + 1):
if(prime[i]):
sum += i
return sum
| 0 | 682 |
mbpp
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
while p * p <= n:
if prime[p] == True:
i = p * 2
while i <= n:
prime[i] = False
i += p
p += 1
sum = 0
for i in range (2,n + 1):
if(prime[i]):
sum += i
return sum
|
transformation_equalto_exclamation_variable
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
while p * p <= n:
if prime[p] != True:
i = p * 2
while i <= n:
prime[i] = False
i += p
p += 1
sum = 0
for i in range (2,n + 1):
if(prime[i]):
sum += i
return sum
| 0 | 682 |
mbpp
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
while p * p <= n:
if prime[p] == True:
i = p * 2
while i <= n:
prime[i] = False
i += p
p += 1
sum = 0
for i in range (2,n + 1):
if(prime[i]):
sum += i
return sum
|
transformation_false_true_variable
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
while p * p <= n:
if prime[p] == True:
i = p * 2
while i <= n:
prime[i] = True
i += p
p += 1
sum = 0
for i in range (2,n + 1):
if(prime[i]):
sum += i
return sum
| 0 | 682 |
mbpp
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
while p * p <= n:
if prime[p] == True:
i = p * 2
while i <= n:
prime[i] = False
i += p
p += 1
sum = 0
for i in range (2,n + 1):
if(prime[i]):
sum += i
return sum
|
transformation_dissimilar_code_injection_0
|
def min_cost(cost, m, n):
R = 3
C = 3
tc = [[0 for x in range(C)] for x in range(R)]
tc[0][0] = cost[0][0]
for i in range(1, m+1):
tc[i][0] = tc[i-1][0] + cost[i][0]
for j in range(1, n+1):
tc[0][j] = tc[0][j-1] + cost[0][j]
for i in range(1, m+1):
for j in range(1, n+1):
tc[i][j] = min(tc[i-1][j-1], tc[i-1][j], tc[i][j-1]) + cost[i][j]
return tc[m][n]
| 0 | 682 |
mbpp
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
while p * p <= n:
if prime[p] == True:
i = p * 2
while i <= n:
prime[i] = False
i += p
p += 1
sum = 0
for i in range (2,n + 1):
if(prime[i]):
sum += i
return sum
|
transformation_dissimilar_code_injection_1
|
def similar_elements(test_tup1, test_tup2):
res = tuple(set(test_tup1) & set(test_tup2))
return (res)
| 0 | 682 |
mbpp
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
while p * p <= n:
if prime[p] == True:
i = p * 2
while i <= n:
prime[i] = False
i += p
p += 1
sum = 0
for i in range (2,n + 1):
if(prime[i]):
sum += i
return sum
|
transformation_dissimilar_code_injection_2
|
def is_not_prime(n):
import math
result = False
for i in range(2,int(math.sqrt(n)) + 1):
if n % i == 0:
result = True
return result
| 0 | 682 |
mbpp
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
while p * p <= n:
if prime[p] == True:
i = p * 2
while i <= n:
prime[i] = False
i += p
p += 1
sum = 0
for i in range (2,n + 1):
if(prime[i]):
sum += i
return sum
|
transformation_dissimilar_code_injection_3
|
def heap_queue_largest(nums,n):
import heapq as hq
largest_nums = hq.nlargest(n, nums)
return largest_nums
| 0 | 682 |
mbpp
|
def sum_Of_Primes(n):
prime = [True] * (n + 1)
p = 2
while p * p <= n:
if prime[p] == True:
i = p * 2
while i <= n:
prime[i] = False
i += p
p += 1
sum = 0
for i in range (2,n + 1):
if(prime[i]):
sum += i
return sum
|
transformation_dissimilar_code_injection_4
|
def count_ways(n):
A = [0] * (n + 1)
B = [0] * (n + 1)
A[0] = 1
A[1] = 0
B[0] = 0
B[1] = 1
for i in range(2, n+1):
A[i] = A[i - 2] + 2 * B[i - 1]
B[i] = A[i - 1] + B[i - 2]
return A[n]
| 0 | 682 |
mbpp
|
def freq_element(test_tup):
from collections import defaultdict
res = defaultdict(int)
for ele in test_tup:
res[ele] += 1
return (str(dict(res)))
|
transformation_dead_code_insert
|
def freq_element(test_tup):
from collections import defaultdict
_i_4 = 0
if _i_4 < _i_4:
res[ele] += 1
res = defaultdict(int)
for ele in test_tup:
res[ele] += 1
return str(dict(res))
| 1 | 683 |
mbpp
|
def freq_element(test_tup):
from collections import defaultdict
res = defaultdict(int)
for ele in test_tup:
res[ele] += 1
return (str(dict(res)))
|
transformation_for_while_loop
|
def freq_element(test_tup):
from collections import defaultdict
res = defaultdict(int)
_ele_i = 0
while _ele_i < len(test_tup):
ele = test_tup[_ele_i]
res[ele] += 1
_ele_i += 1
return str(dict(res))
| 1 | 683 |
mbpp
|
def freq_element(test_tup):
from collections import defaultdict
res = defaultdict(int)
for ele in test_tup:
res[ele] += 1
return (str(dict(res)))
|
transformation_operand_swap
|
def freq_element(test_tup):
from collections import defaultdict
res = defaultdict(int)
for ele in test_tup:
res[ele] += 1
return str(dict(res))
| 1 | 683 |
mbpp
|
def freq_element(test_tup):
from collections import defaultdict
res = defaultdict(int)
for ele in test_tup:
res[ele] += 1
return (str(dict(res)))
|
transformation_rename_variable_cb
|
def freq_element(test_tup):
from collections import defaultdict
obj = defaultdict(int)
for ele in test_tup:
obj[ele] += 1
return str(dict(obj))
| 1 | 683 |
mbpp
|
def freq_element(test_tup):
from collections import defaultdict
res = defaultdict(int)
for ele in test_tup:
res[ele] += 1
return (str(dict(res)))
|
transformation_rename_variable_naive
|
def freq_element(test_tup):
from collections import defaultdict
VAR_0 = defaultdict(int)
for ele in test_tup:
VAR_0[ele] += 1
return str(dict(VAR_0))
| 1 | 683 |
mbpp
|
def freq_element(test_tup):
from collections import defaultdict
res = defaultdict(int)
for ele in test_tup:
res[ele] += 1
return (str(dict(res)))
|
transformation_rename_variable_rn
|
def freq_element(test_tup):
from collections import defaultdict
xr4 = defaultdict(int)
for ele in test_tup:
xr4[ele] += 1
return str(dict(xr4))
| 1 | 683 |
mbpp
|
def freq_element(test_tup):
from collections import defaultdict
res = defaultdict(int)
for ele in test_tup:
res[ele] += 1
return (str(dict(res)))
|
transformation_add_sub_variable
|
def freq_element(test_tup):
from collections import defaultdict
res = defaultdict(int)
for ele in test_tup:
res[ele] -= 1
return (str(dict(res)))
| 0 | 683 |
mbpp
|
def freq_element(test_tup):
from collections import defaultdict
res = defaultdict(int)
for ele in test_tup:
res[ele] += 1
return (str(dict(res)))
|
transformation_dissimilar_code_injection_0
|
def min_cost(cost, m, n):
R = 3
C = 3
tc = [[0 for x in range(C)] for x in range(R)]
tc[0][0] = cost[0][0]
for i in range(1, m+1):
tc[i][0] = tc[i-1][0] + cost[i][0]
for j in range(1, n+1):
tc[0][j] = tc[0][j-1] + cost[0][j]
for i in range(1, m+1):
for j in range(1, n+1):
tc[i][j] = min(tc[i-1][j-1], tc[i-1][j], tc[i][j-1]) + cost[i][j]
return tc[m][n]
| 0 | 683 |
mbpp
|
def freq_element(test_tup):
from collections import defaultdict
res = defaultdict(int)
for ele in test_tup:
res[ele] += 1
return (str(dict(res)))
|
transformation_dissimilar_code_injection_1
|
def similar_elements(test_tup1, test_tup2):
res = tuple(set(test_tup1) & set(test_tup2))
return (res)
| 0 | 683 |
mbpp
|
def freq_element(test_tup):
from collections import defaultdict
res = defaultdict(int)
for ele in test_tup:
res[ele] += 1
return (str(dict(res)))
|
transformation_dissimilar_code_injection_2
|
def is_not_prime(n):
import math
result = False
for i in range(2,int(math.sqrt(n)) + 1):
if n % i == 0:
result = True
return result
| 0 | 683 |
mbpp
|
def freq_element(test_tup):
from collections import defaultdict
res = defaultdict(int)
for ele in test_tup:
res[ele] += 1
return (str(dict(res)))
|
transformation_dissimilar_code_injection_3
|
def heap_queue_largest(nums,n):
import heapq as hq
largest_nums = hq.nlargest(n, nums)
return largest_nums
| 0 | 683 |
mbpp
|
def freq_element(test_tup):
from collections import defaultdict
res = defaultdict(int)
for ele in test_tup:
res[ele] += 1
return (str(dict(res)))
|
transformation_dissimilar_code_injection_4
|
def count_ways(n):
A = [0] * (n + 1)
B = [0] * (n + 1)
A[0] = 1
A[1] = 0
B[0] = 0
B[1] = 1
for i in range(2, n+1):
A[i] = A[i - 2] + 2 * B[i - 1]
B[i] = A[i - 1] + B[i - 2]
return A[n]
| 0 | 683 |
mbpp
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
|
transformation_dead_code_insert
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float("inf")
jumps[0] = 0
for i in range(1, n):
_i_6 = 0
while _i_6 > _i_6:
return jumps[n - 1]
jumps[i] = float("inf")
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float("inf")):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n - 1]
| 1 | 686 |
mbpp
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
|
transformation_for_while_loop
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float("inf")
jumps[0] = 0
i = 1
while i < n:
jumps[i] = float("inf")
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float("inf")):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
i += 1
return jumps[n - 1]
| 1 | 686 |
mbpp
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
|
transformation_operand_swap
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (0 == n) or (arr[0] == 0):
return float("inf")
jumps[0] = 0
for i in range(1, n):
jumps[i] = float("inf")
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float("inf")):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n - 1]
| 1 | 686 |
mbpp
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
|
transformation_rename_variable_cb
|
def min_jumps(arr, n):
arr2 = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float("inf")
arr2[0] = 0
for i in range(1, n):
arr2[i] = float("inf")
for j in range(i):
if (i <= j + arr[j]) and (arr2[j] != float("inf")):
arr2[i] = min(arr2[i], arr2[j] + 1)
break
return arr2[n - 1]
| 1 | 686 |
mbpp
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
|
transformation_rename_variable_naive
|
def min_jumps(arr, n):
VAR_0 = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float("inf")
VAR_0[0] = 0
for i in range(1, n):
VAR_0[i] = float("inf")
for j in range(i):
if (i <= j + arr[j]) and (VAR_0[j] != float("inf")):
VAR_0[i] = min(VAR_0[i], VAR_0[j] + 1)
break
return VAR_0[n - 1]
| 1 | 686 |
mbpp
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
|
transformation_rename_variable_rn
|
def min_jumps(arr, n):
j4xkg = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float("inf")
j4xkg[0] = 0
for i in range(1, n):
j4xkg[i] = float("inf")
for j in range(i):
if (i <= j + arr[j]) and (j4xkg[j] != float("inf")):
j4xkg[i] = min(j4xkg[i], j4xkg[j] + 1)
break
return j4xkg[n - 1]
| 1 | 686 |
mbpp
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
|
transformation_add_sub_variable
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j - arr[j]) and (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
| 0 | 686 |
mbpp
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
|
transformation_sub_add_variable
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n+1]
| 0 | 686 |
mbpp
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
|
transformation_lesser_greater_variable
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i >= j + arr[j]) and (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
| 0 | 686 |
mbpp
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
|
transformation_equalto_exclamation_variable
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n != 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
| 0 | 686 |
mbpp
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
|
transformation_exclamation_equalto_variable
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] == float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
| 0 | 686 |
mbpp
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
|
transformation_and_or_variable
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j + arr[j]) or (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
| 0 | 686 |
mbpp
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
|
transformation_or_and_variable
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) and (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
| 0 | 686 |
mbpp
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
|
transformation_dissimilar_code_injection_0
|
def min_cost(cost, m, n):
R = 3
C = 3
tc = [[0 for x in range(C)] for x in range(R)]
tc[0][0] = cost[0][0]
for i in range(1, m+1):
tc[i][0] = tc[i-1][0] + cost[i][0]
for j in range(1, n+1):
tc[0][j] = tc[0][j-1] + cost[0][j]
for i in range(1, m+1):
for j in range(1, n+1):
tc[i][j] = min(tc[i-1][j-1], tc[i-1][j], tc[i][j-1]) + cost[i][j]
return tc[m][n]
| 0 | 686 |
mbpp
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
|
transformation_dissimilar_code_injection_1
|
def similar_elements(test_tup1, test_tup2):
res = tuple(set(test_tup1) & set(test_tup2))
return (res)
| 0 | 686 |
mbpp
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
|
transformation_dissimilar_code_injection_2
|
def is_not_prime(n):
import math
result = False
for i in range(2,int(math.sqrt(n)) + 1):
if n % i == 0:
result = True
return result
| 0 | 686 |
mbpp
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
|
transformation_dissimilar_code_injection_3
|
def heap_queue_largest(nums,n):
import heapq as hq
largest_nums = hq.nlargest(n, nums)
return largest_nums
| 0 | 686 |
mbpp
|
def min_jumps(arr, n):
jumps = [0 for i in range(n)]
if (n == 0) or (arr[0] == 0):
return float('inf')
jumps[0] = 0
for i in range(1, n):
jumps[i] = float('inf')
for j in range(i):
if (i <= j + arr[j]) and (jumps[j] != float('inf')):
jumps[i] = min(jumps[i], jumps[j] + 1)
break
return jumps[n-1]
|
transformation_dissimilar_code_injection_4
|
def count_ways(n):
A = [0] * (n + 1)
B = [0] * (n + 1)
A[0] = 1
A[1] = 0
B[0] = 0
B[1] = 1
for i in range(2, n+1):
A[i] = A[i - 2] + 2 * B[i - 1]
B[i] = A[i - 1] + B[i - 2]
return A[n]
| 0 | 686 |
mbpp
|
def last_Two_Digits(N):
if (N >= 10):
return
fac = 1
for i in range(1,N + 1):
fac = (fac * i) % 100
return (fac)
|
transformation_dead_code_insert
|
def last_Two_Digits(N):
if N >= 10:
_i_1 = 0
if _i_1 > _i_1:
fac = 1
return
fac = 1
for i in range(1, N + 1):
fac = (fac * i) % 100
return fac
| 1 | 689 |
mbpp
|
def last_Two_Digits(N):
if (N >= 10):
return
fac = 1
for i in range(1,N + 1):
fac = (fac * i) % 100
return (fac)
|
transformation_for_while_loop
|
def last_Two_Digits(N):
if N >= 10:
return
fac = 1
i = 1
while i < N + 1:
fac = (fac * i) % 100
i += 1
return fac
| 1 | 689 |
mbpp
|
def last_Two_Digits(N):
if (N >= 10):
return
fac = 1
for i in range(1,N + 1):
fac = (fac * i) % 100
return (fac)
|
transformation_operand_swap
|
def last_Two_Digits(N):
if 10 <= N:
return
fac = 1
for i in range(1, N + 1):
fac = (fac * i) % 100
return fac
| 1 | 689 |
mbpp
|
def last_Two_Digits(N):
if (N >= 10):
return
fac = 1
for i in range(1,N + 1):
fac = (fac * i) % 100
return (fac)
|
transformation_rename_variable_cb
|
def last_Two_Digits(N):
if N >= 10:
return
N2 = 1
for i in range(1, N + 1):
N2 = (N2 * i) % 100
return N2
| 1 | 689 |
mbpp
|
def last_Two_Digits(N):
if (N >= 10):
return
fac = 1
for i in range(1,N + 1):
fac = (fac * i) % 100
return (fac)
|
transformation_rename_variable_naive
|
def last_Two_Digits(N):
if N >= 10:
return
VAR_0 = 1
for i in range(1, N + 1):
VAR_0 = (VAR_0 * i) % 100
return VAR_0
| 1 | 689 |
mbpp
|
def last_Two_Digits(N):
if (N >= 10):
return
fac = 1
for i in range(1,N + 1):
fac = (fac * i) % 100
return (fac)
|
transformation_rename_variable_rn
|
def last_Two_Digits(N):
if N >= 10:
return
l2S = 1
for i in range(1, N + 1):
l2S = (l2S * i) % 100
return l2S
| 1 | 689 |
mbpp
|
def last_Two_Digits(N):
if (N >= 10):
return
fac = 1
for i in range(1,N + 1):
fac = (fac * i) % 100
return (fac)
|
transformation_add_sub_variable
|
def last_Two_Digits(N):
if (N >= 10):
return
fac = 1
for i in range(1,N - 1):
fac = (fac * i) % 100
return (fac)
| 0 | 689 |
mbpp
|
def last_Two_Digits(N):
if (N >= 10):
return
fac = 1
for i in range(1,N + 1):
fac = (fac * i) % 100
return (fac)
|
transformation_mul_div_variable
|
def last_Two_Digits(N):
if (N >= 10):
return
fac = 1
for i in range(1,N + 1):
fac = (fac / i) % 100
return (fac)
| 0 | 689 |
mbpp
|
def last_Two_Digits(N):
if (N >= 10):
return
fac = 1
for i in range(1,N + 1):
fac = (fac * i) % 100
return (fac)
|
transformation_greater_lesser_variable
|
def last_Two_Digits(N):
if (N <= 10):
return
fac = 1
for i in range(1,N + 1):
fac = (fac * i) % 100
return (fac)
| 0 | 689 |
mbpp
|
def last_Two_Digits(N):
if (N >= 10):
return
fac = 1
for i in range(1,N + 1):
fac = (fac * i) % 100
return (fac)
|
transformation_dissimilar_code_injection_0
|
def min_cost(cost, m, n):
R = 3
C = 3
tc = [[0 for x in range(C)] for x in range(R)]
tc[0][0] = cost[0][0]
for i in range(1, m+1):
tc[i][0] = tc[i-1][0] + cost[i][0]
for j in range(1, n+1):
tc[0][j] = tc[0][j-1] + cost[0][j]
for i in range(1, m+1):
for j in range(1, n+1):
tc[i][j] = min(tc[i-1][j-1], tc[i-1][j], tc[i][j-1]) + cost[i][j]
return tc[m][n]
| 0 | 689 |
mbpp
|
def last_Two_Digits(N):
if (N >= 10):
return
fac = 1
for i in range(1,N + 1):
fac = (fac * i) % 100
return (fac)
|
transformation_dissimilar_code_injection_1
|
def similar_elements(test_tup1, test_tup2):
res = tuple(set(test_tup1) & set(test_tup2))
return (res)
| 0 | 689 |
mbpp
|
def last_Two_Digits(N):
if (N >= 10):
return
fac = 1
for i in range(1,N + 1):
fac = (fac * i) % 100
return (fac)
|
transformation_dissimilar_code_injection_2
|
def is_not_prime(n):
import math
result = False
for i in range(2,int(math.sqrt(n)) + 1):
if n % i == 0:
result = True
return result
| 0 | 689 |
mbpp
|
def last_Two_Digits(N):
if (N >= 10):
return
fac = 1
for i in range(1,N + 1):
fac = (fac * i) % 100
return (fac)
|
transformation_dissimilar_code_injection_3
|
def heap_queue_largest(nums,n):
import heapq as hq
largest_nums = hq.nlargest(n, nums)
return largest_nums
| 0 | 689 |
mbpp
|
def last_Two_Digits(N):
if (N >= 10):
return
fac = 1
for i in range(1,N + 1):
fac = (fac * i) % 100
return (fac)
|
transformation_dissimilar_code_injection_4
|
def count_ways(n):
A = [0] * (n + 1)
B = [0] * (n + 1)
A[0] = 1
A[1] = 0
B[0] = 0
B[1] = 1
for i in range(2, n+1):
A[i] = A[i - 2] + 2 * B[i - 1]
B[i] = A[i - 1] + B[i - 2]
return A[n]
| 0 | 689 |
mbpp
|
def remove_multiple_spaces(text1):
import re
return (re.sub(' +',' ',text1))
|
transformation_dead_code_insert
|
def remove_multiple_spaces(text1):
_i_8 = 0
while _i_8 < _i_8:
import re
import re
return re.sub(" +", " ", text1)
| 1 | 690 |
mbpp
|
def remove_multiple_spaces(text1):
import re
return (re.sub(' +',' ',text1))
|
transformation_for_while_loop
|
def remove_multiple_spaces(text1):
import re
return re.sub(" +", " ", text1)
| 1 | 690 |
mbpp
|
def remove_multiple_spaces(text1):
import re
return (re.sub(' +',' ',text1))
|
transformation_operand_swap
|
def remove_multiple_spaces(text1):
import re
return re.sub(" +", " ", text1)
| 1 | 690 |
mbpp
|
def remove_multiple_spaces(text1):
import re
return (re.sub(' +',' ',text1))
|
transformation_rename_variable_cb
|
def remove_multiple_spaces(line):
import re
return re.sub(" +", " ", line)
| 1 | 690 |
mbpp
|
def remove_multiple_spaces(text1):
import re
return (re.sub(' +',' ',text1))
|
transformation_rename_variable_naive
|
def remove_multiple_spaces(VAR_0):
import re
return re.sub(" +", " ", VAR_0)
| 1 | 690 |
mbpp
|
def remove_multiple_spaces(text1):
import re
return (re.sub(' +',' ',text1))
|
transformation_rename_variable_rn
|
def remove_multiple_spaces(Wn172):
import re
return re.sub(" +", " ", Wn172)
| 1 | 690 |
mbpp
|
def remove_multiple_spaces(text1):
import re
return (re.sub(' +',' ',text1))
|
transformation_add_sub_variable
|
def remove_multiple_spaces(text1):
import re
return (re.sub(' -',' ',text1))
| 0 | 690 |
mbpp
|
def remove_multiple_spaces(text1):
import re
return (re.sub(' +',' ',text1))
|
transformation_dissimilar_code_injection_0
|
def min_cost(cost, m, n):
R = 3
C = 3
tc = [[0 for x in range(C)] for x in range(R)]
tc[0][0] = cost[0][0]
for i in range(1, m+1):
tc[i][0] = tc[i-1][0] + cost[i][0]
for j in range(1, n+1):
tc[0][j] = tc[0][j-1] + cost[0][j]
for i in range(1, m+1):
for j in range(1, n+1):
tc[i][j] = min(tc[i-1][j-1], tc[i-1][j], tc[i][j-1]) + cost[i][j]
return tc[m][n]
| 0 | 690 |
mbpp
|
def remove_multiple_spaces(text1):
import re
return (re.sub(' +',' ',text1))
|
transformation_dissimilar_code_injection_1
|
def similar_elements(test_tup1, test_tup2):
res = tuple(set(test_tup1) & set(test_tup2))
return (res)
| 0 | 690 |
mbpp
|
def remove_multiple_spaces(text1):
import re
return (re.sub(' +',' ',text1))
|
transformation_dissimilar_code_injection_2
|
def is_not_prime(n):
import math
result = False
for i in range(2,int(math.sqrt(n)) + 1):
if n % i == 0:
result = True
return result
| 0 | 690 |
mbpp
|
def remove_multiple_spaces(text1):
import re
return (re.sub(' +',' ',text1))
|
transformation_dissimilar_code_injection_3
|
def heap_queue_largest(nums,n):
import heapq as hq
largest_nums = hq.nlargest(n, nums)
return largest_nums
| 0 | 690 |
mbpp
|
def remove_multiple_spaces(text1):
import re
return (re.sub(' +',' ',text1))
|
transformation_dissimilar_code_injection_4
|
def count_ways(n):
A = [0] * (n + 1)
B = [0] * (n + 1)
A[0] = 1
A[1] = 0
B[0] = 0
B[1] = 1
for i in range(2, n+1):
A[i] = A[i - 2] + 2 * B[i - 1]
B[i] = A[i - 1] + B[i - 2]
return A[n]
| 0 | 690 |
mbpp
|
def extract_unique(test_dict):
res = list(sorted({ele for val in test_dict.values() for ele in val}))
return res
|
transformation_dead_code_insert
|
def extract_unique(test_dict):
while False:
return res
res = list(sorted({ele for val in test_dict.values() for ele in val}))
return res
| 1 | 691 |
mbpp
|
def extract_unique(test_dict):
res = list(sorted({ele for val in test_dict.values() for ele in val}))
return res
|
transformation_for_while_loop
|
def extract_unique(test_dict):
res = list(sorted({ele for val in test_dict.values() for ele in val}))
return res
| 1 | 691 |
mbpp
|
def extract_unique(test_dict):
res = list(sorted({ele for val in test_dict.values() for ele in val}))
return res
|
transformation_operand_swap
|
def extract_unique(test_dict):
res = list(sorted({ele for val in test_dict.values() for ele in val}))
return res
| 1 | 691 |
mbpp
|
def extract_unique(test_dict):
res = list(sorted({ele for val in test_dict.values() for ele in val}))
return res
|
transformation_rename_variable_cb
|
def extract_unique(test_dict):
res = list(sorted({ele for res2 in test_dict.values() for ele in res2}))
return res
| 1 | 691 |
mbpp
|
def extract_unique(test_dict):
res = list(sorted({ele for val in test_dict.values() for ele in val}))
return res
|
transformation_rename_variable_naive
|
def extract_unique(test_dict):
VAR_0 = list(sorted({ele for val in test_dict.values() for ele in val}))
return VAR_0
| 1 | 691 |
mbpp
|
def extract_unique(test_dict):
res = list(sorted({ele for val in test_dict.values() for ele in val}))
return res
|
transformation_rename_variable_rn
|
def extract_unique(ZQ48Kn9w0):
res = list(sorted({ele for val in ZQ48Kn9w0.values() for ele in val}))
return res
| 1 | 691 |
mbpp
|
def extract_unique(test_dict):
res = list(sorted({ele for val in test_dict.values() for ele in val}))
return res
|
transformation_dissimilar_code_injection_0
|
def min_cost(cost, m, n):
R = 3
C = 3
tc = [[0 for x in range(C)] for x in range(R)]
tc[0][0] = cost[0][0]
for i in range(1, m+1):
tc[i][0] = tc[i-1][0] + cost[i][0]
for j in range(1, n+1):
tc[0][j] = tc[0][j-1] + cost[0][j]
for i in range(1, m+1):
for j in range(1, n+1):
tc[i][j] = min(tc[i-1][j-1], tc[i-1][j], tc[i][j-1]) + cost[i][j]
return tc[m][n]
| 0 | 691 |
mbpp
|
def extract_unique(test_dict):
res = list(sorted({ele for val in test_dict.values() for ele in val}))
return res
|
transformation_dissimilar_code_injection_1
|
def similar_elements(test_tup1, test_tup2):
res = tuple(set(test_tup1) & set(test_tup2))
return (res)
| 0 | 691 |
mbpp
|
def extract_unique(test_dict):
res = list(sorted({ele for val in test_dict.values() for ele in val}))
return res
|
transformation_dissimilar_code_injection_2
|
def is_not_prime(n):
import math
result = False
for i in range(2,int(math.sqrt(n)) + 1):
if n % i == 0:
result = True
return result
| 0 | 691 |
mbpp
|
def extract_unique(test_dict):
res = list(sorted({ele for val in test_dict.values() for ele in val}))
return res
|
transformation_dissimilar_code_injection_3
|
def heap_queue_largest(nums,n):
import heapq as hq
largest_nums = hq.nlargest(n, nums)
return largest_nums
| 0 | 691 |
mbpp
|
def extract_unique(test_dict):
res = list(sorted({ele for val in test_dict.values() for ele in val}))
return res
|
transformation_dissimilar_code_injection_4
|
def count_ways(n):
A = [0] * (n + 1)
B = [0] * (n + 1)
A[0] = 1
A[1] = 0
B[0] = 0
B[1] = 1
for i in range(2, n+1):
A[i] = A[i - 2] + 2 * B[i - 1]
B[i] = A[i - 1] + B[i - 2]
return A[n]
| 0 | 691 |
mbpp
|
def check_greater(test_tup1, test_tup2):
res = all(x < y for x, y in zip(test_tup1, test_tup2))
return (res)
|
transformation_dead_code_insert
|
def check_greater(test_tup1, test_tup2):
for _i_0 in range(0):
return res
res = all(x < y for x, y in zip(test_tup1, test_tup2))
return res
| 1 | 692 |
mbpp
|
def check_greater(test_tup1, test_tup2):
res = all(x < y for x, y in zip(test_tup1, test_tup2))
return (res)
|
transformation_for_while_loop
|
def check_greater(test_tup1, test_tup2):
res = all(x < y for x, y in zip(test_tup1, test_tup2))
return res
| 1 | 692 |
mbpp
|
def check_greater(test_tup1, test_tup2):
res = all(x < y for x, y in zip(test_tup1, test_tup2))
return (res)
|
transformation_operand_swap
|
def check_greater(test_tup1, test_tup2):
res = all(y > x for x, y in zip(test_tup1, test_tup2))
return res
| 1 | 692 |
mbpp
|
def check_greater(test_tup1, test_tup2):
res = all(x < y for x, y in zip(test_tup1, test_tup2))
return (res)
|
transformation_rename_variable_cb
|
def check_greater(test, test_tup2):
res = all(x < y for x, y in zip(test, test_tup2))
return res
| 1 | 692 |
mbpp
|
def check_greater(test_tup1, test_tup2):
res = all(x < y for x, y in zip(test_tup1, test_tup2))
return (res)
|
transformation_rename_variable_naive
|
def check_greater(test_tup1, test_tup2):
res = all(VAR_0 < y for VAR_0, y in zip(test_tup1, test_tup2))
return res
| 1 | 692 |
mbpp
|
def check_greater(test_tup1, test_tup2):
res = all(x < y for x, y in zip(test_tup1, test_tup2))
return (res)
|
transformation_rename_variable_rn
|
def check_greater(test_tup1, test_tup2):
res = all(x < y2 for x, y2 in zip(test_tup1, test_tup2))
return res
| 1 | 692 |
mbpp
|
def check_greater(test_tup1, test_tup2):
res = all(x < y for x, y in zip(test_tup1, test_tup2))
return (res)
|
transformation_lesser_greater_variable
|
def check_greater(test_tup1, test_tup2):
res = all(x > y for x, y in zip(test_tup1, test_tup2))
return (res)
| 0 | 692 |
mbpp
|
def check_greater(test_tup1, test_tup2):
res = all(x < y for x, y in zip(test_tup1, test_tup2))
return (res)
|
transformation_dissimilar_code_injection_0
|
def min_cost(cost, m, n):
R = 3
C = 3
tc = [[0 for x in range(C)] for x in range(R)]
tc[0][0] = cost[0][0]
for i in range(1, m+1):
tc[i][0] = tc[i-1][0] + cost[i][0]
for j in range(1, n+1):
tc[0][j] = tc[0][j-1] + cost[0][j]
for i in range(1, m+1):
for j in range(1, n+1):
tc[i][j] = min(tc[i-1][j-1], tc[i-1][j], tc[i][j-1]) + cost[i][j]
return tc[m][n]
| 0 | 692 |
mbpp
|
def check_greater(test_tup1, test_tup2):
res = all(x < y for x, y in zip(test_tup1, test_tup2))
return (res)
|
transformation_dissimilar_code_injection_1
|
def similar_elements(test_tup1, test_tup2):
res = tuple(set(test_tup1) & set(test_tup2))
return (res)
| 0 | 692 |
mbpp
|
def check_greater(test_tup1, test_tup2):
res = all(x < y for x, y in zip(test_tup1, test_tup2))
return (res)
|
transformation_dissimilar_code_injection_2
|
def is_not_prime(n):
import math
result = False
for i in range(2,int(math.sqrt(n)) + 1):
if n % i == 0:
result = True
return result
| 0 | 692 |
mbpp
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.