category
stringclasses 5
values | question
stringlengths 20
555
| answer
stringlengths 1
20
| solution_abst
stringlengths 1
287
| solution_code
stringlengths 27
5.97k
|
---|---|---|---|---|
Comparison | Find the one who got the biggest number: Jungkook with 6 times 3, Yoongi with 4, and Yuna with 5. | Jungkook | [OP_LIST_SOL] Jungkook Yoongi Yuna [OP_LIST_EOL] [OP_LIST_SOL] 6 3 [OP_MUL] 4 5 [OP_LIST_EOL] 1 [OP_LIST_MAX] [OP_LIST_INDEX] [OP_LIST_POP] [OP_LIST_GET] | var_a = 'Jungkook'
var_b = 'Yoongi'
var_c = 'Yuna'
list_a= []
if "/" in str(var_c):
var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_d = 6
var_e = 3
var_f = var_d * var_e
var_g = 4
var_h = 5
list_b= []
if "/" in str(var_h):
var_h = eval(str(var_h))
list_b.append(var_h)
if "/" in str(var_g):
var_g = eval(str(var_g))
list_b.append(var_g)
if "/" in str(var_f):
var_f = eval(str(var_f))
list_b.append(var_f)
list_b.reverse()
var_i = 1
list_c=list_b.copy()
list_c.sort()
var_j = list_c[-var_i]
var_k = list_b.index(var_j)+1
var_l = list_a[var_k-1]
print(var_l) |
Geometry | A cuboid-shaped fishbowl measuring 15 cm (cm) wide and 20 cm (cm) long contains water 10 cm (cm) high. When one stone was completely submerged in the water, the water level rose to 15 cm (cm). What is the volume in cubic centimeters (cm3) of this stone? | 1500 | 15 20 [OP_MUL] 15 10 [OP_SUB] [OP_MUL] | var_a = 15
var_b = 20
var_c = var_a * var_b
var_d = 15
var_e = 10
var_f = var_d - var_e
var_g = var_c * var_f
print(int(var_g)) |
Arithmetic calculation | When you add 3 consecutive natural numbers, you get 48. What is the multiplication of the largest of these numbers and the smallest of these numbers? | 255 | 48 3 [OP_DIV] 3 2 [OP_FDIV] [OP_ADD] 48 3 [OP_DIV] 3 2 [OP_FDIV] [OP_SUB] [OP_MUL] | var_a = 48
var_b = 3
var_c = var_a / var_b
var_d = 3
var_e = 2
var_f = var_d // var_e
var_g = var_c + var_f
var_h = 48
var_i = 3
var_j = var_h / var_i
var_k = 3
var_l = 2
var_m = var_k // var_l
var_n = var_j - var_m
var_o = var_g * var_n
print(int(var_o)) |
Arithmetic calculation | What is the product of the numbers 4, 7, and 25? | 700 | 4 7 [OP_MUL] 25 [OP_MUL] | var_a = 4
var_b = 7
var_c = var_a * var_b
var_d = 25
var_e = var_c * var_d
print(int(var_e)) |
Geometry | The surface area of a cube is 600 square centimeters (cm2). Find the length of one side. | 10 | 600 6 [OP_DIV] 1/2 [OP_POW] | var_a = 600
var_b = 6
var_c = var_a / var_b
var_d = 0.5
var_e = var_c ** var_d
print(int(var_e)) |
Geometry | We are going to attach square tiles with a side of 25 centimeters (cm) to a rectangular wall measuring 3+1/4 meters (m) wide and 2+3/4 meters (m) long. How many tiles can you put on this wall? | 143 | 3 1/4 [OP_ADD] 25 100 [OP_DIV] [OP_FDIV] 2 3/4 [OP_ADD] 25 100 [OP_DIV] [OP_FDIV] [OP_MUL] | var_a = 3
var_b = 0.25
var_c = var_a + var_b
var_d = 25
var_e = 100
var_f = var_d / var_e
var_g = var_c // var_f
var_h = 2
var_i = 0.75
var_j = var_h + var_i
var_k = 25
var_l = 100
var_m = var_k / var_l
var_n = var_j // var_m
var_o = var_g * var_n
print(int(var_o)) |
Arithmetic calculation | In a 10.5 km bike course, Yoongi took a break after going 1.5 kilometers (km). If he went another 3730 meters (m), how many meters (m) is the length of the remaining course? | 5270 | 10.5 1000 [OP_MUL] 1.5 1000 [OP_MUL] [OP_SUB] 3730 [OP_SUB] | var_a = 10.5
var_b = 1000
var_c = var_a * var_b
var_d = 1.5
var_e = 1000
var_f = var_d * var_e
var_g = var_c - var_f
var_h = 3730
var_i = var_g - var_h
print(int(var_i)) |
Comparison | There are 3 apples, 2 plums, and 5 peaches in the fruit basket. When Hyeonsu closes his eyes and chooses one fruit at random from the fruit basket, which fruit is most likely to be chosen? | peaches | [OP_LIST_SOL] apples plums peaches [OP_LIST_EOL] [OP_LIST_SOL] 3 2 5 [OP_LIST_EOL] 1 [OP_LIST_MAX] [OP_LIST_INDEX] [OP_LIST_POP] [OP_LIST_GET] | var_a = 'apples'
var_b = 'plums'
var_c = 'peaches'
list_a= []
if "/" in str(var_c):
var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_d = 3
var_e = 2
var_f = 5
list_b= []
if "/" in str(var_f):
var_f = eval(str(var_f))
list_b.append(var_f)
if "/" in str(var_e):
var_e = eval(str(var_e))
list_b.append(var_e)
if "/" in str(var_d):
var_d = eval(str(var_d))
list_b.append(var_d)
list_b.reverse()
var_g = 1
list_c=list_b.copy()
list_c.sort()
var_h = list_c[-var_g]
var_i = list_b.index(var_h)+1
var_j = list_a[var_i-1]
print(var_j) |
Arithmetic calculation | There are marbles of three different colors. The average number of red and yellow marbles is 26.5, the average number of blue and yellow marbles is 34.5, and the average number of red and blue marbles is 29. What is the average number of the three marbles? | 30 | 26.5 34.5 [OP_ADD] 29 [OP_ADD] 3 [OP_DIV] | var_a = 26.5
var_b = 34.5
var_c = var_a + var_b
var_d = 29
var_e = var_c + var_d
var_f = 3
var_g = var_e / var_f
print(int(var_g)) |
Possibility | Hoseok intends to distribute the 7 notebooks to his older sister and older brother. The older sister and older brother each receive at least one notebook. How many total ways to hand out notebooks? | 6 | 7 2 1 [OP_MUL] [OP_SUB] 1 [OP_ADD] | var_a = 7
var_b = 2
var_c = 1
var_d = var_b * var_c
var_e = var_a - var_d
var_f = 1
var_g = var_e + var_f
print(int(var_g)) |
Arithmetic calculation | It takes 6.64 kg (kg) of glutinous rice flour to make one glutinous rice cake. After making a glutinous rice cake with 202.66 kg (kg) of glutinous rice flour, find how many grams (g) of glutinous rice flour is left. | 3460 | 202.66 6.64 [OP_MOD] 1000 [OP_MUL] | var_a = 202.66
var_b = 6.64
var_c = var_a % var_b
var_d = 1000
var_e = var_c * var_d
print(int(eval('{:.2f}'.format(round(var_e+1e-10,2))))) |
Arithmetic calculation | Find the sum of the natural numbers from 6 to 21 | 216 | 6 21 1 [OP_LIST_ARANGE] [OP_LIST_SUM] | var_a = 6
var_b = 21
var_c = 1
list_a = [i for i in range(var_a, var_b + 1, var_c)]
list_a = [float(i) for i in list_a]
var_d = sum(list_a)
print(int(var_d)) |
Correspondence | What number must go in B in order to satisfy A78-21B=364? | 4 | A78-21B=364 B [OP_DIGIT_UNK_SOLVER] | var_a = 'A78-21B=364'
var_b = 'B'
ans_dict = dict()
var_a = var_a.replace('×','*')
var_a = var_a.replace('x','*')
var_a = var_a.replace('÷','/')
variable_candi = set(['A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z'])
for v in set(var_a):
if v in variable_candi:
ans_dict[v] = 1
candi = list(itertools.product('0123456789', repeat=len(ans_dict)))
for c in candi:
temp = var_a
for i, (k, _) in enumerate(ans_dict.items()):
temp = temp.replace(k, str(c[i]))
term_list = []
op_list = []
temp_c = ''
for tc in temp:
if tc not in '+-*/=><().':
temp_c += tc
else:
op_list.append(tc)
term_list.append(temp_c)
temp_c = ''
term_list.append(temp_c)
new_eq = ''
for i in range(len(op_list)):
new_eq += str(int(term_list[i]))+op_list[i]
new_eq += str(int(term_list[-1]))
if len(new_eq) == len(var_a):
new_eq=new_eq.replace('=', '==')
new_eq=new_eq.replace('>==', '>=')
new_eq=new_eq.replace('<==', '<=')
eval_result = False
try:
eval_result = eval(new_eq)
except:
pass
if eval_result:
for i, (k, _) in enumerate(ans_dict.items()):
ans_dict[k] = int(c[i])
var_c = ans_dict[var_b]
print(int(var_c)) |
Arithmetic calculation | A car needs 0.14 liters (l) of gasoline to travel 1 kilometer (km). This car ran for 2 hours and 30 minutes at 93.6 kilometers (km) per hour. Find how many liters (L) of gasoline were used. | 32.76 | 0.14 93.6 [OP_MUL] 2 30 60 [OP_DIV] [OP_ADD] [OP_MUL] | var_a = 0.14
var_b = 93.6
var_c = var_a * var_b
var_d = 2
var_e = 30
var_f = 60
var_g = var_e / var_f
var_h = var_d + var_g
var_i = var_c * var_h
print('{:.2f}'.format(round(var_i+1e-10,2))) |
Possibility | Using the number cards 1, 6, and 8 all once, find the sum of the second largest three-digit number and the third largest three-digit number. | 1434 | [OP_LIST_SOL] 1 6 8 [OP_LIST_EOL] 3 [OP_LIST_GET_PERM] 2 [OP_LIST_MAX] 3 [OP_LIST_GET] [OP_ADD] | var_a = 1
var_b = 6
var_c = 8
list_a= []
if "/" in str(var_c):
var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_d = 3
list_b = [str(i) for i in list_a]
list_b = list(itertools.permutations(list_b, var_d))
list_b = [''.join(num_list) for num_list in list_b]
list_b = [str_num for str_num in list_b if str_num[0] != '0']
list_b = [float(i) for i in list_b]
var_e = 2
list_c=list_b.copy()
list_c.sort()
var_f = list_c[-var_e]
var_g = 3
var_h = list_b[var_g-1]
var_i = var_f + var_h
print(int(var_i)) |
Geometry | There is a piece of colored paper in the shape of a square with a side length of 4 centimeters (cm). The four sides of this colored paper were cut into diamond shapes by connecting the two equally divided dots. Find the area of this rhombus. | 8 | 4 4 [OP_MUL] 2 [OP_DIV] | var_a = 4
var_b = 4
var_c = var_a * var_b
var_d = 2
var_e = var_c / var_d
print(int(var_e)) |
Correspondence | Gyeongyeon rides a bicycle for half of the entire route, travels another 300 meters (m), rides a bus to travel half of the remaining route, and then travels another 400 meters (m) before arriving at his destination. Find how many meters (m) is the total path traveled by Gyeongyeon. | 2200 | 0 400 [OP_ADD] 1 1/2 [OP_SUB] [OP_DIV] 300 [OP_ADD] 1 1/2 [OP_SUB] [OP_DIV] | var_a = 0
var_b = 400
var_c = var_a + var_b
var_d = 1
var_e = 0.5
var_f = var_d - var_e
var_g = var_c / var_f
var_h = 300
var_i = var_g + var_h
var_j = 1
var_k = 0.5
var_l = var_j - var_k
var_m = var_i / var_l
print(int(var_m)) |
Correspondence | There are two different numbers: A and B. Find the value of A×B in the two-digit subtraction formula of A2-5A=B3. | 27 | A2-5A=B3 A [OP_DIGIT_UNK_SOLVER] A2-5A=B3 B [OP_DIGIT_UNK_SOLVER] [OP_MUL] | var_a = 'A2-5A=B3'
var_b = 'A'
ans_dict = dict()
var_a = var_a.replace('×','*')
var_a = var_a.replace('x','*')
var_a = var_a.replace('÷','/')
variable_candi = set(['A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z'])
for v in set(var_a):
if v in variable_candi:
ans_dict[v] = 1
candi = list(itertools.product('0123456789', repeat=len(ans_dict)))
for c in candi:
temp = var_a
for i, (k, _) in enumerate(ans_dict.items()):
temp = temp.replace(k, str(c[i]))
term_list = []
op_list = []
temp_c = ''
for tc in temp:
if tc not in '+-*/=><().':
temp_c += tc
else:
op_list.append(tc)
term_list.append(temp_c)
temp_c = ''
term_list.append(temp_c)
new_eq = ''
for i in range(len(op_list)):
new_eq += str(int(term_list[i]))+op_list[i]
new_eq += str(int(term_list[-1]))
if len(new_eq) == len(var_a):
new_eq=new_eq.replace('=', '==')
new_eq=new_eq.replace('>==', '>=')
new_eq=new_eq.replace('<==', '<=')
eval_result = False
try:
eval_result = eval(new_eq)
except:
pass
if eval_result:
for i, (k, _) in enumerate(ans_dict.items()):
ans_dict[k] = int(c[i])
var_c = ans_dict[var_b]
var_d = 'A2-5A=B3'
var_e = 'B'
ans_dict = dict()
var_d = var_d.replace('×','*')
var_d = var_d.replace('x','*')
var_d = var_d.replace('÷','/')
variable_candi = set(['A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z'])
for v in set(var_d):
if v in variable_candi:
ans_dict[v] = 1
candi = list(itertools.product('0123456789', repeat=len(ans_dict)))
for c in candi:
temp = var_d
for i, (k, _) in enumerate(ans_dict.items()):
temp = temp.replace(k, str(c[i]))
term_list = []
op_list = []
temp_c = ''
for tc in temp:
if tc not in '+-*/=><().':
temp_c += tc
else:
op_list.append(tc)
term_list.append(temp_c)
temp_c = ''
term_list.append(temp_c)
new_eq = ''
for i in range(len(op_list)):
new_eq += str(int(term_list[i]))+op_list[i]
new_eq += str(int(term_list[-1]))
if len(new_eq) == len(var_d):
new_eq=new_eq.replace('=', '==')
new_eq=new_eq.replace('>==', '>=')
new_eq=new_eq.replace('<==', '<=')
eval_result = False
try:
eval_result = eval(new_eq)
except:
pass
if eval_result:
for i, (k, _) in enumerate(ans_dict.items()):
ans_dict[k] = int(c[i])
var_f = ans_dict[var_e]
var_g = var_c * var_f
print(int(var_g)) |
Arithmetic calculation | A few years ago, when Jimin was 16, his father was 47. If the father is twice Jimin's age this year, how many years have passed? | 15 | 47 16 2 [OP_MUL] [OP_SUB] 2 1 [OP_SUB] [OP_DIV] | var_a = 47
var_b = 16
var_c = 2
var_d = var_b * var_c
var_e = var_a - var_d
var_f = 2
var_g = 1
var_h = var_f - var_g
var_i = var_e / var_h
print(int(var_i)) |
Possibility | How many times can you choose and buy 2 of 4 different fruits? | 6 | 4 2 [OP_COMB] | var_a = 4
var_b = 2
var_c = 1
var_a = int(var_a)
var_b = int(var_b)
for i, elem in enumerate(range(var_b)):
var_c = var_c * (var_a-i)
for i, elem in enumerate(range(var_b)):
var_c = var_c / (i+1)
print(int(var_c)) |
Possibility | Find the difference between the largest and smallest two-digit numbers that can be formed by picking two different numbers from 8, 3, 4, and 6. | 52 | [OP_LIST_SOL] 8 3 4 6 [OP_LIST_EOL] 2 [OP_LIST_GET_PERM] 1 [OP_LIST_MAX] 1 [OP_LIST_MIN] [OP_SUB] | var_a = 8
var_b = 3
var_c = 4
var_d = 6
list_a= []
if "/" in str(var_d):
var_d = eval(str(var_d))
list_a.append(var_d)
if "/" in str(var_c):
var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_e = 2
list_b = [str(i) for i in list_a]
list_b = list(itertools.permutations(list_b, var_e))
list_b = [''.join(num_list) for num_list in list_b]
list_b = [str_num for str_num in list_b if str_num[0] != '0']
list_b = [float(i) for i in list_b]
var_f = 1
list_c=list_b.copy()
list_c.sort()
var_g = list_c[-var_f]
var_h = 1
list_d=list_b.copy()
list_d.sort()
var_i = list_d[var_h-1]
var_j = var_g - var_i
print(int(var_j)) |
Correspondence | If the number 26 greater than a number is 50, find the number that is 9 times the number. | 216 | 50 26 [OP_SUB] 9 [OP_MUL] | var_a = 50
var_b = 26
var_c = var_a - var_b
var_d = 9
var_e = var_c * var_d
print(int(var_e)) |
Arithmetic calculation | We are trying to put 2135 marbles, 100 each in a barrel. Find the minimum number of barrels needed to hold the marbles. | 22 | 2153 100 [OP_DIV] 1 [OP_CEIL] | var_a = 2153
var_b = 100
var_c = var_a / var_b
var_d = 1
var_e=int(((var_c+9*10**(var_d-2))//(10**(var_d-1)))*10**(var_d-1))
print(int(var_e)) |
Comparison | Pencil, eraser, pen, ruler, and notebook are on the desk in this order. When you swap the positions of the pen and the notebook, in what position (in ordinal number) would the notebook be? | 5 | [OP_LIST_SOL] Pencil eraser pen ruler notebook [OP_LIST_EOL] notebook [OP_LIST_INDEX] | var_a = 'Pencil'
var_b = 'eraser'
var_c = 'pen'
var_d = 'ruler'
var_e = 'notebook'
list_a= []
if "/" in str(var_e):
var_e = eval(str(var_e))
list_a.append(var_e)
if "/" in str(var_d):
var_d = eval(str(var_d))
list_a.append(var_d)
if "/" in str(var_c):
var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_f = 'notebook'
var_g = list_a.index(var_f)+1
print(int(var_g)) |
Correspondence | A is 238 and B is 143 greater than that. Find A+C when B is the value of C minus 304. | 637 | 238 238 143 [OP_SUB] 304 [OP_ADD] [OP_ADD] | var_a = 238
var_b = 238
var_c = 143
var_d = var_b - var_c
var_e = 304
var_f = var_d + var_e
var_g = var_a + var_f
print(int(var_g)) |
Geometry | Taehyung is the 6th shortest in the class, and Seokjin is the next shortest. In what order is Seokjin short in the classroom? | 7 | 6 1 [OP_ADD] | var_a = 6
var_b = 1
var_c = var_a + var_b
print(int(var_c)) |
Comparison | After filling a 1 liter (l) 400 milliliter (ml) water bottle and a 2800 milliliter (ml) tank full of water, they poured all the water into a basin, and the basin was full. Which one can have more water inside - the basin or a tank with 4 liters (l) and 100 milliliters (ml)? | basin | [OP_LIST_SOL] tank basin [OP_LIST_EOL] [OP_LIST_SOL] 4 1000 [OP_MUL] 100 [OP_ADD] 2800 1 1000 [OP_MUL] 400 [OP_ADD] [OP_ADD] [OP_LIST_EOL] 1 [OP_LIST_MAX] [OP_LIST_INDEX] [OP_LIST_POP] [OP_LIST_GET] | var_a = 'tank'
var_b = 'basin'
list_a= []
if "/" in str(var_b):
var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_c = 4
var_d = 1000
var_e = var_c * var_d
var_f = 100
var_g = var_e + var_f
var_h = 2800
var_i = 1
var_j = 1000
var_k = var_i * var_j
var_l = 400
var_m = var_k + var_l
var_n = var_h + var_m
list_b= []
if "/" in str(var_n):
var_n = eval(str(var_n))
list_b.append(var_n)
if "/" in str(var_g):
var_g = eval(str(var_g))
list_b.append(var_g)
list_b.reverse()
var_o = 1
list_c=list_b.copy()
list_c.sort()
var_p = list_c[-var_o]
var_q = list_b.index(var_p)+1
var_r = list_a[var_q-1]
print(var_r) |
Correspondence | Find the single digit number greater than 0 and less than 2. | 1 | 1 9 1 [OP_LIST_ARANGE] 0 [OP_LIST_MORE] 2 [OP_LIST_LESS] 1 [OP_LIST_GET] | var_a = 1
var_b = 9
var_c = 1
list_a = [i for i in range(var_a, var_b + 1, var_c)]
var_d = 0
list_b = []
for i in list_a:
if i > var_d:
list_b.append(i)
var_e = 2
list_c = []
for i in list_b:
if i < var_e:
list_c.append(i)
var_f = 1
var_g = list_c[var_f-1]
print(int(var_g)) |
Correspondence | The homeroom teacher expected the sum of the students' final exam scores to increase by 2152 compared to the sum of their midterm exam scores, but it only increased by 1264. What is the difference between the teacher's estimate and the actual score? | 888 | 2152 1264 [OP_SUB] | var_a = 2152
var_b = 1264
var_c = var_a - var_b
print(int(var_c)) |
Geometry | A parallelogram has a height of 11 centimeters (cm) and an area of 44 square centimeters (cm2). What is the length of the base of this parallelogram in centimeters (cm)? | 4 | 44 11 [OP_DIV] | var_a = 44
var_b = 11
var_c = var_a / var_b
print(int(var_c)) |
Possibility | Three of the five numbers 0, 1, 2, 3, and 4 were used to make a three-digit even number. If you can use the same number multiple times, how many even numbers can you make? | 60 | [OP_LIST_SOL] 0 1 2 3 4 [OP_LIST_EOL] 3 [OP_LIST_GET_PRODUCT] 2 [OP_LIST_DIVISIBLE] [OP_LIST_LEN] | var_a = 0
var_b = 1
var_c = 2
var_d = 3
var_e = 4
list_a= []
if "/" in str(var_e):
var_e = eval(str(var_e))
list_a.append(var_e)
if "/" in str(var_d):
var_d = eval(str(var_d))
list_a.append(var_d)
if "/" in str(var_c):
var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_f = 3
list_b = [str(i) for i in list_a]
list_b = list(itertools.product(list_b, repeat=var_f))
list_b = [''.join(num_list) for num_list in list_b]
list_b = [str_num for str_num in list_b if str_num[0] != '0']
list_b = [float(i) for i in list_b]
var_g = 2
list_c = []
var_g = int(var_g)
for i in list_b:
i = int(i)
if i % var_g == 0:
list_c.append(i)
var_h = len(list_c)
print(int(var_h)) |
Geometry | There is a rhombus with two diagonals measuring 9 centimeters (cm) and 14 centimeters (cm), respectively. Find the area of this figure. | 63 | 9 14 [OP_MUL] 2 [OP_DIV] | var_a = 9
var_b = 14
var_c = var_a * var_b
var_d = 2
var_e = var_c / var_d
print(int(var_e)) |
Arithmetic calculation | I joined 15 pieces of paper tape, each of which is 30 centimeters (cm) wide and 2 centimeters (cm) long, to each other to extend it. If the length of the overlapping glued part is 2 centimeters (cm) long, what is the total width of the created piece of paper tape in centimeters (cm)? | 422 | 30 15 [OP_MUL] 15 1 [OP_SUB] 2 [OP_MUL] [OP_SUB] | var_a = 30
var_b = 15
var_c = var_a * var_b
var_d = 15
var_e = 1
var_f = var_d - var_e
var_g = 2
var_h = var_f * var_g
var_i = var_c - var_h
print(int(var_i)) |
Geometry | We are going to make a long rope by tying 64 ropes each 25 centimeters (cm) in length. By tying two ropes together and making a knot, the length is reduced by 3 centimeters (cm). What is the length of the newly made rope? | 1411 | 25 64 [OP_MUL] 3 64 1 [OP_SUB] [OP_MUL] [OP_SUB] | var_a = 25
var_b = 64
var_c = var_a * var_b
var_d = 3
var_e = 64
var_f = 1
var_g = var_e - var_f
var_h = var_d * var_g
var_i = var_c - var_h
print(int(var_i)) |
Geometry | A square was created by arranging 10 square-shaped colored papers horizontally and vertically without gaps. If the colored papers on the periphery is red and the colored papers on the inside is yellow, how many yellow colored papers are there? | 64 | 10 2 [OP_SUB] 2 [OP_POW] | var_a = 10
var_b = 2
var_c = var_a - var_b
var_d = 2
var_e = var_c ** var_d
print(int(var_e)) |
Correspondence | In the addition between three-digit numbers, 6A5+10B=748, what number should go in B? | 3 | 6A5+10B=748 B [OP_DIGIT_UNK_SOLVER] | var_a = '6A5+10B=748'
var_b = 'B'
ans_dict = dict()
var_a = var_a.replace('×','*')
var_a = var_a.replace('x','*')
var_a = var_a.replace('÷','/')
variable_candi = set(['A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z'])
for v in set(var_a):
if v in variable_candi:
ans_dict[v] = 1
candi = list(itertools.product('0123456789', repeat=len(ans_dict)))
for c in candi:
temp = var_a
for i, (k, _) in enumerate(ans_dict.items()):
temp = temp.replace(k, str(c[i]))
term_list = []
op_list = []
temp_c = ''
for tc in temp:
if tc not in '+-*/=><().':
temp_c += tc
else:
op_list.append(tc)
term_list.append(temp_c)
temp_c = ''
term_list.append(temp_c)
new_eq = ''
for i in range(len(op_list)):
new_eq += str(int(term_list[i]))+op_list[i]
new_eq += str(int(term_list[-1]))
if len(new_eq) == len(var_a):
new_eq=new_eq.replace('=', '==')
new_eq=new_eq.replace('>==', '>=')
new_eq=new_eq.replace('<==', '<=')
eval_result = False
try:
eval_result = eval(new_eq)
except:
pass
if eval_result:
for i, (k, _) in enumerate(ans_dict.items()):
ans_dict[k] = int(c[i])
var_c = ans_dict[var_b]
print(int(var_c)) |
Geometry | You have a picture frame in the shape of a square with a perimeter 100 centimeters (cm) long. How many centimeters (cm) of colored tape are needed to decorate one side of this frame? | 25 | 100 4 [OP_DIV] | var_a = 100
var_b = 4
var_c = var_a / var_b
print(int(var_c)) |
Comparison | Box A and B are 3 centimeters (cm) and 3.5 centimeters (cm), respectively. When Taehyung stacked 16 boxes of A and Yoongi stacked 14 boxes of B, who would be the one that piled boxes higher? | Yoongi | [OP_LIST_SOL] Taehyung Yoongi [OP_LIST_EOL] [OP_LIST_SOL] 3 16 [OP_MUL] 3.5 14 [OP_MUL] [OP_LIST_EOL] 1 [OP_LIST_MAX] [OP_LIST_INDEX] [OP_LIST_POP] [OP_LIST_GET] | var_a = 'Taehyung'
var_b = 'Yoongi'
list_a= []
if "/" in str(var_b):
var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_c = 3
var_d = 16
var_e = var_c * var_d
var_f = 3.5
var_g = 14
var_h = var_f * var_g
list_b= []
if "/" in str(var_h):
var_h = eval(str(var_h))
list_b.append(var_h)
if "/" in str(var_e):
var_e = eval(str(var_e))
list_b.append(var_e)
list_b.reverse()
var_i = 1
list_c=list_b.copy()
list_c.sort()
var_j = list_c[-var_i]
var_k = list_b.index(var_j)+1
var_l = list_a[var_k-1]
print(var_l) |
Correspondence | When you divide A by 9, the quotient is 2 and the remainder is 6. Find A at this time. | 24 | 9 2 [OP_MUL] 6 [OP_ADD] | var_a = 9
var_b = 2
var_c = var_a * var_b
var_d = 6
var_e = var_c + var_d
print(int(var_e)) |
Comparison | Namjoon came second, and Yoongi went right in front of him. What's Yoongi's rank? | 1 | 2 1 [OP_SUB] | var_a = 2
var_b = 1
var_c = var_a - var_b
print(int(var_c)) |
Arithmetic calculation | A baby koala in the zoo weighs 2 kilograms (kg) and 460 grams (g). How many grams (g) does the baby koala weigh? | 2460 | 2 1000 [OP_MUL] 460 [OP_ADD] | var_a = 2
var_b = 1000
var_c = var_a * var_b
var_d = 460
var_e = var_c + var_d
print(int(var_e)) |
Comparison | Among the numbers greater than 0 and less than 100, write the common multiples of 4 and 6 in order from smallest. Find the 7th number from the left. | 84 | 0 1 [OP_ADD] 100 1 [OP_SUB] 1 [OP_LIST_ARANGE] 4 6 [OP_LCM] [OP_LIST_DIVISIBLE] 7 [OP_LIST_GET] | var_a = 0
var_b = 1
var_c = var_a + var_b
var_d = 100
var_e = 1
var_f = var_d - var_e
var_g = 1
list_a = [i for i in range(var_c, var_f + 1, var_g)]
var_h = 4
var_i = 6
var_j = var_i * var_h / math.gcd(int(var_i), int(var_h))
list_b = []
var_j = int(var_j)
for i in list_a:
i = int(i)
if i % var_j == 0:
list_b.append(i)
var_k = 7
var_l = list_b[var_k-1]
print(int(var_l)) |
Comparison | If a number less than 1.1 is selected among 1.4, 9/10, 1.2, 0.5, and 13/10, and arranged in ascending order, which number comes first? | 0.9 | [OP_LIST_SOL] 1.4 9/10 1.2 0.5 13/10 [OP_LIST_EOL] 1.1 [OP_LIST_LESS] 1 [OP_LIST_MAX] | var_a = 1.4
var_b = 0.9
var_c = 1.2
var_d = 0.5
var_e = 1.3
list_a= []
if "/" in str(var_e):
var_e = eval(str(var_e))
list_a.append(var_e)
if "/" in str(var_d):
var_d = eval(str(var_d))
list_a.append(var_d)
if "/" in str(var_c):
var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_f = 1.1
list_b = []
for i in list_a:
if i < var_f:
list_b.append(i)
var_g = 1
list_c=list_b.copy()
list_c.sort()
var_h = list_c[-var_g]
print('{:.2f}'.format(round(var_h+1e-10,2))) |
Correspondence | A number that is the 1/100 of that number is said to be 0.28 greater than 31.76. Find that number. | 3204 | 31.76 0.28 [OP_ADD] 1 100 [OP_DIV] [OP_DIV] | var_a = 31.76
var_b = 0.28
var_c = var_a + var_b
var_d = 1
var_e = 100
var_f = var_d / var_e
var_g = var_c / var_f
print(int(var_g)) |
Geometry | There is a square with the sum of its four sides measuring 56 centimeters (cm). Divide this square into 4 equal parts to make smaller squares. When you make one large square out of these 441 small squares, find the perimeter of that square. | 588 | 56 4 [OP_DIV] 4 1/2 [OP_POW] [OP_DIV] 441 1/2 [OP_POW] [OP_MUL] 4 [OP_MUL] | var_a = 56
var_b = 4
var_c = var_a / var_b
var_d = 4
var_e = 0.5
var_f = var_d ** var_e
var_g = var_c / var_f
var_h = 441
var_i = 0.5
var_j = var_h ** var_i
var_k = var_g * var_j
var_l = 4
var_m = var_k * var_l
print(int(var_m)) |
Correspondence | The six-digit number 12ABC8 is a multiple of 137. In this case, how many numbers fit the 3-digit number ABC? | 7 | 12ABC8 [OP_GEN_POSSIBLE_LIST] 137 [OP_LIST_DIVISIBLE] [OP_LIST_LEN] | var_a = '12ABC8'
ans_dict = dict()
var_a = str(var_a)
list_a = []
variable_candi = set(['A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z'])
for v in set(var_a):
if v in variable_candi:
ans_dict[v] = 0
candi = list(itertools.product('0123456789', repeat=len(ans_dict)))
for c in candi:
temp = var_a
for i, (k, _) in enumerate(ans_dict.items()):
temp = temp.replace(k, str(c[i]))
if len(var_a) == len(str(int(temp))):
new_elem = int(temp)
list_a.append(new_elem)
var_b = 137
list_b = []
var_b = int(var_b)
for i in list_a:
i = int(i)
if i % var_b == 0:
list_b.append(i)
var_c = len(list_b)
print(int(var_c)) |
Arithmetic calculation | The box that holds 20 books is full of books (a) and books (b). If there are 4 more books (a) than books (b), how many books (a) are there? | 12 | 20 4 [OP_ADD] 2 [OP_FDIV] | var_a = 20
var_b = 4
var_c = var_a + var_b
var_d = 2
var_e = var_c // var_d
print(int(var_e)) |
Arithmetic calculation | Three people each have one 8-kilogram (kg) dumbbell, and two people each have one 7-kilogram (kg) dumbbell. How many kilograms (kg) do all 5 dumbbells weigh? | 38 | 3 8 [OP_MUL] 2 7 [OP_MUL] [OP_ADD] | var_a = 3
var_b = 8
var_c = var_a * var_b
var_d = 2
var_e = 7
var_f = var_d * var_e
var_g = var_c + var_f
print(int(var_g)) |
Possibility | There are 9 number cards, one each with a number from 1 to 9 written on it. You take out 8 cards and add all the numbers written on the cards. Find the sum of all possible sums. | 360 | 1 9 1 [OP_LIST_ARANGE] 8 [OP_LIST_GET_PERM] [OP_LIST_NUM2SUM] [OP_LIST_SOL] [OP_LIST_EOL] [OP_SET_DIFFERENCE] [OP_LIST_SUM] | var_a = 1
var_b = 9
var_c = 1
list_a = [i for i in range(var_a, var_b + 1, var_c)]
var_d = 8
list_b = [str(i) for i in list_a]
list_b = list(itertools.permutations(list_b, var_d))
list_b = [''.join(num_list) for num_list in list_b]
list_b = [str_num for str_num in list_b if str_num[0] != '0']
list_b = [float(i) for i in list_b]
list_c=[]
for i in list_b:
var_e = 0
i = int(i)
while i//10 > 0:
var_e = var_e + i%10
i = i//10
var_e = var_e + i%10
list_c.append(var_e)
list_d= []
list_d.reverse()
list_e = list(set(list_c) - set(list_d))
list_e = [float(i) for i in list_e]
var_f = sum(list_e)
print(int(var_f)) |
Correspondence | When 23 is divided by A, the quotient is 3 and the remainder is 2. If A is a natural number, what is A in this case? | 7 | 23 2 [OP_SUB] 3 [OP_DIV] | var_a = 23
var_b = 2
var_c = var_a - var_b
var_d = 3
var_e = var_c / var_d
print(int(var_e)) |
Arithmetic calculation | Suppose you pay 30 won when you call for 10 seconds. How much do you have to pay for 2 minutes 40 seconds phone call? | 480 | 2 60 [OP_MUL] 40 [OP_ADD] 10 [OP_DIV] 30 [OP_MUL] | var_a = 2
var_b = 60
var_c = var_a * var_b
var_d = 40
var_e = var_c + var_d
var_f = 10
var_g = var_e / var_f
var_h = 30
var_i = var_g * var_h
print(int(var_i)) |
Correspondence | I had to add 954 to a number but mistakenly subtracted it to get 468. When the calculation is correctly done, what is the result? | 2376 | 468 954 [OP_ADD] 954 [OP_ADD] | var_a = 468
var_b = 954
var_c = var_a + var_b
var_d = 954
var_e = var_c + var_d
print(int(var_e)) |
Geometry | There is a box in the shape of a cuboid measuring 80 centimeters (cm) wide, 75 centimeters (cm) long, and 120 centimeters (cm) high. If you double the length of all sides of this box to make a new box, find the volume in cubic meters (m3) of the new box. | 5.76 | 80 100 [OP_DIV] 2 [OP_MUL] 75 100 [OP_DIV] 2 [OP_MUL] 120 100 [OP_DIV] 2 [OP_MUL] [OP_MUL] [OP_MUL] | var_a = 80
var_b = 100
var_c = var_a / var_b
var_d = 2
var_e = var_c * var_d
var_f = 75
var_g = 100
var_h = var_f / var_g
var_i = 2
var_j = var_h * var_i
var_k = 120
var_l = 100
var_m = var_k / var_l
var_n = 2
var_o = var_m * var_n
var_p = var_j * var_o
var_q = var_e * var_p
print('{:.2f}'.format(round(var_q+1e-10,2))) |
Correspondence | When AB3+36=269 is said to hold, what number should go in A? | 2 | AB3+36=269 A [OP_DIGIT_UNK_SOLVER] | var_a = 'AB3+36=269'
var_b = 'A'
ans_dict = dict()
var_a = var_a.replace('×','*')
var_a = var_a.replace('x','*')
var_a = var_a.replace('÷','/')
variable_candi = set(['A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z'])
for v in set(var_a):
if v in variable_candi:
ans_dict[v] = 1
candi = list(itertools.product('0123456789', repeat=len(ans_dict)))
for c in candi:
temp = var_a
for i, (k, _) in enumerate(ans_dict.items()):
temp = temp.replace(k, str(c[i]))
term_list = []
op_list = []
temp_c = ''
for tc in temp:
if tc not in '+-*/=><().':
temp_c += tc
else:
op_list.append(tc)
term_list.append(temp_c)
temp_c = ''
term_list.append(temp_c)
new_eq = ''
for i in range(len(op_list)):
new_eq += str(int(term_list[i]))+op_list[i]
new_eq += str(int(term_list[-1]))
if len(new_eq) == len(var_a):
new_eq=new_eq.replace('=', '==')
new_eq=new_eq.replace('>==', '>=')
new_eq=new_eq.replace('<==', '<=')
eval_result = False
try:
eval_result = eval(new_eq)
except:
pass
if eval_result:
for i, (k, _) in enumerate(ans_dict.items()):
ans_dict[k] = int(c[i])
var_c = ans_dict[var_b]
print(int(var_c)) |
Correspondence | 300 is divisible by 25. Find the smallest number greater than 300 that when divided by 25 has a remainder of 24. | 324 | 300 24 [OP_ADD] | var_a = 300
var_b = 24
var_c = var_a + var_b
print(int(var_c)) |
Possibility | Find the product of the largest two-digit number and the smallest two-digit number among the two-digit numbers that can be formed using four number cards 1, 3, 5, and 8, only once each. | 1105 | [OP_LIST_SOL] 1 3 5 8 [OP_LIST_EOL] 2 [OP_LIST_GET_PERM] 1 [OP_LIST_MAX] 1 [OP_LIST_MIN] [OP_MUL] | var_a = 1
var_b = 3
var_c = 5
var_d = 8
list_a= []
if "/" in str(var_d):
var_d = eval(str(var_d))
list_a.append(var_d)
if "/" in str(var_c):
var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_e = 2
list_b = [str(i) for i in list_a]
list_b = list(itertools.permutations(list_b, var_e))
list_b = [''.join(num_list) for num_list in list_b]
list_b = [str_num for str_num in list_b if str_num[0] != '0']
list_b = [float(i) for i in list_b]
var_f = 1
list_c=list_b.copy()
list_c.sort()
var_g = list_c[-var_f]
var_h = 1
list_d=list_b.copy()
list_d.sort()
var_i = list_d[var_h-1]
var_j = var_g * var_i
print(int(var_j)) |
Comparison | Students are standing in a line. Yoojung is standing at the very last. Eunjung is standing 5th from the front. When there are 8 students standing between Eunjeong and Yoojeong, how many students are in line? | 14 | 5 8 [OP_ADD] 1 [OP_ADD] | var_a = 5
var_b = 8
var_c = var_a + var_b
var_d = 1
var_e = var_c + var_d
print(int(var_e)) |
Possibility | What is the smallest three-digit number that can be formed using all 1, 0, and 7? | 107 | [OP_LIST_SOL] 1 0 7 [OP_LIST_EOL] [OP_LIST_LEN] [OP_LIST_GET_PERM] 1 [OP_LIST_MIN] | var_a = 1
var_b = 0
var_c = 7
list_a= []
if "/" in str(var_c):
var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_d = len(list_a)
list_b = [str(i) for i in list_a]
list_b = list(itertools.permutations(list_b, var_d))
list_b = [''.join(num_list) for num_list in list_b]
list_b = [str_num for str_num in list_b if str_num[0] != '0']
list_b = [float(i) for i in list_b]
var_e = 1
list_c=list_b.copy()
list_c.sort()
var_f = list_c[var_e-1]
print(int(var_f)) |
Geometry | Red and yellow colored pencils were neatly arranged in 10 rows both horizontally and vertically. If the colored pencils placed around the perimeter are red and the colored pencils placed inside are yellow, how many yellow colored pencils are there in all? | 64 | 10 2 [OP_SUB] 2 [OP_POW] | var_a = 10
var_b = 2
var_c = var_a - var_b
var_d = 2
var_e = var_c ** var_d
print(int(var_e)) |
Possibility | Using 3 out of 4, 3, 7, 9, what is the second largest number with the units digit of 3? | 943 | [OP_LIST_SOL] 4 3 7 9 [OP_LIST_EOL] 3 [OP_LIST_GET_PERM] 1 3 [OP_LIST_SEARCH_FIXED_DIGIT] 2 [OP_LIST_MAX] | var_a = 4
var_b = 3
var_c = 7
var_d = 9
list_a= []
if "/" in str(var_d):
var_d = eval(str(var_d))
list_a.append(var_d)
if "/" in str(var_c):
var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_e = 3
list_b = [str(i) for i in list_a]
list_b = list(itertools.permutations(list_b, var_e))
list_b = [''.join(num_list) for num_list in list_b]
list_b = [str_num for str_num in list_b if str_num[0] != '0']
list_b = [float(i) for i in list_b]
var_f = 1
var_g = 3
list_c = []
var_f = int(var_f)
var_g = int(var_g)
for i in list_b:
i = int(i)
if (i//var_f)%10 == var_g:
list_c.append(i)
var_h = 2
list_d=list_c.copy()
list_d.sort()
var_i = list_d[-var_h]
print(int(var_i)) |
Possibility | Yoongi wants to choose three toys for Jungkook's birthday present. When trying to choose one gift out of 10 different toys, how many ways are there in choosing a toy? | 120 | 10 3 [OP_COMB] | var_a = 10
var_b = 3
var_c = 1
var_a = int(var_a)
var_b = int(var_b)
for i, elem in enumerate(range(var_b)):
var_c = var_c * (var_a-i)
for i, elem in enumerate(range(var_b)):
var_c = var_c / (i+1)
print(int(var_c)) |
Arithmetic calculation | When a weight was hung from the spring, the length of the spring increased by 29.75 centimeters (cm) compared to before the weight was hung. If the length of the spring with nothing hanging is 4.25 centimeters (cm), how many times the length of the spring with the weight is the length of the spring with nothing hanging? | 8 | 29.75 4.25 [OP_ADD] 4.25 [OP_DIV] | var_a = 29.75
var_b = 4.25
var_c = var_a + var_b
var_d = 4.25
var_e = var_c / var_d
print(int(var_e)) |
Comparison | Jennie drank 0.2 liters (L) more juice than Jisoo, and Jennie drank 9/5 liters (L) of juice. Who drank the least juice when Jisoo drank 3/10 of a liter (L) less than Rohee? | Jisoo | [OP_LIST_SOL] Jennie Jisoo Rohee [OP_LIST_EOL] [OP_LIST_SOL] 9/5 9/5 0.2 [OP_SUB] 9/5 0.2 [OP_SUB] 3/10 [OP_ADD] [OP_LIST_EOL] 1 [OP_LIST_MIN] [OP_LIST_INDEX] [OP_LIST_POP] [OP_LIST_GET] | var_a = 'Jennie'
var_b = 'Jisoo'
var_c = 'Rohee'
list_a= []
if "/" in str(var_c):
var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_d = 1.8
var_e = 1.8
var_f = 0.2
var_g = var_e - var_f
var_h = 1.8
var_i = 0.2
var_j = var_h - var_i
var_k = 0.3
var_l = var_j + var_k
list_b= []
if "/" in str(var_l):
var_l = eval(str(var_l))
list_b.append(var_l)
if "/" in str(var_g):
var_g = eval(str(var_g))
list_b.append(var_g)
if "/" in str(var_d):
var_d = eval(str(var_d))
list_b.append(var_d)
list_b.reverse()
var_m = 1
list_c=list_b.copy()
list_c.sort()
var_n = list_c[var_m-1]
var_o = list_b.index(var_n)+1
var_p = list_a[var_o-1]
print(var_p) |
Arithmetic calculation | Suyeong's family drank 0.4 of the total milk today, and the remaining milk was 0.69 liters (L). Find how many liters (L) of milk were in the beginning. | 1.15 | 0.69 1 0.4 [OP_SUB] [OP_DIV] | var_a = 0.69
var_b = 1
var_c = 0.4
var_d = var_b - var_c
var_e = var_a / var_d
print('{:.2f}'.format(round(var_e+1e-10,2))) |
Correspondence | Add a number to 55, divide it by 7, then add 40 and multiply by 5 is 555. Find a number. | 442 | 555 5 [OP_DIV] 40 [OP_SUB] 7 [OP_MUL] 55 [OP_SUB] | var_a = 555
var_b = 5
var_c = var_a / var_b
var_d = 40
var_e = var_c - var_d
var_f = 7
var_g = var_e * var_f
var_h = 55
var_i = var_g - var_h
print(int(var_i)) |
Comparison | We are trying to stack 8 pieces of (a) wood, 11 pieces of (b) wood, and 6 pieces of (c) wood each in a row. If the heights of the blocks (a), (b), (c) are each 2 centimeters (cm), 1.5 centimeters (cm), and 2.5 centimeters (cm) respectively, which of the stacked blocks is the tallest? | (b) | [OP_LIST_SOL] (a) (b) (c) [OP_LIST_EOL] [OP_LIST_SOL] 2 8 [OP_MUL] 1.5 11 [OP_MUL] 2.5 6 [OP_MUL] [OP_LIST_EOL] 1 [OP_LIST_MAX] [OP_LIST_INDEX] [OP_LIST_POP] [OP_LIST_GET] | var_a = '(a)'
var_b = '(b)'
var_c = '(c)'
list_a= []
if "/" in str(var_c):
var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_d = 2
var_e = 8
var_f = var_d * var_e
var_g = 1.5
var_h = 11
var_i = var_g * var_h
var_j = 2.5
var_k = 6
var_l = var_j * var_k
list_b= []
if "/" in str(var_l):
var_l = eval(str(var_l))
list_b.append(var_l)
if "/" in str(var_i):
var_i = eval(str(var_i))
list_b.append(var_i)
if "/" in str(var_f):
var_f = eval(str(var_f))
list_b.append(var_f)
list_b.reverse()
var_m = 1
list_c=list_b.copy()
list_c.sort()
var_n = list_c[-var_m]
var_o = list_b.index(var_n)+1
var_p = list_a[var_o-1]
print(var_p) |
Arithmetic calculation | A train 115 meters (m) long travels at 400 meters (m) per minute. At the same speed, how many minutes would it take for the train to cross the entire length of the 1.625 km (km) bridge? | 4.35 | 115 1.625 1000 [OP_MUL] [OP_ADD] 400 [OP_DIV] | var_a = 115
var_b = 1.625
var_c = 1000
var_d = var_b * var_c
var_e = var_a + var_d
var_f = 400
var_g = var_e / var_f
print('{:.2f}'.format(round(var_g+1e-10,2))) |
Arithmetic calculation | In an elementary school, class (A) planted 225 trees, class (B) planted 48 trees more than class (A), and class (C) planted 24 fewer trees than class (A). How many trees did the three classes plant on average? | 233 | 225 225 48 [OP_ADD] [OP_ADD] 225 24 [OP_SUB] [OP_ADD] 3 [OP_DIV] | var_a = 225
var_b = 225
var_c = 48
var_d = var_b + var_c
var_e = var_a + var_d
var_f = 225
var_g = 24
var_h = var_f - var_g
var_i = var_e + var_h
var_j = 3
var_k = var_i / var_j
print(int(var_k)) |
Geometry | On a map with a scale of 1/250000, we have marked two points with an actual distance of 5 kilometers (km). How many centimeters (cm) is the distance between these points measured with a ruler? | 2 | 5 100 1000 [OP_MUL] [OP_MUL] 1/250000 [OP_MUL] | var_a = 5
var_b = 100
var_c = 1000
var_d = var_b * var_c
var_e = var_a * var_d
var_f = 4e-06
var_g = var_e * var_f
print(int(var_g)) |
Arithmetic calculation | Jungkook's weight is 13 grams (g) lighter than 54 kilograms (kg). Write Jungkook's weight in kilograms (kg). | 53.99 | 54 13 1000 [OP_DIV] [OP_SUB] | var_a = 54
var_b = 13
var_c = 1000
var_d = var_b / var_c
var_e = var_a - var_d
print('{:.2f}'.format(round(var_e+1e-10,2))) |
Arithmetic calculation | To fold colored paper with friends, Jimin gave 11 pieces of it to each of 2 friends and bought 27 new ones. If the number of colored papers Jimin currently has is 63, how many pieces of colored paper did Jimin initially have? | 58 | 63 11 2 [OP_MUL] [OP_ADD] 27 [OP_SUB] | var_a = 63
var_b = 11
var_c = 2
var_d = var_b * var_c
var_e = var_a + var_d
var_f = 27
var_g = var_e - var_f
print(int(var_g)) |
Correspondence | If a certain number is divisible by 72 without any remainder, then it is also divisible by 48. What is the largest value that can satisfy these conditions? | 24 | 72 48 [OP_GCD] | var_a = 72
var_b = 48
var_c = math.gcd(int(var_b), int(var_a))
print(int(var_c)) |
Arithmetic calculation | There is a number with a one's digit of 3, 1st and 2nd decimal places of 0, and 3rd decimal place of 6. How many three-digit decimal numbers are less than 3.01 but greater than this number? | 3 | 0 9 1 [OP_LIST_ARANGE] 6 [OP_LIST_MORE] [OP_LIST_LEN] | var_a = 0
var_b = 9
var_c = 1
list_a = [i for i in range(var_a, var_b + 1, var_c)]
var_d = 6
list_b = []
for i in list_a:
if i > var_d:
list_b.append(i)
var_e = len(list_b)
print(int(var_e)) |
Arithmetic calculation | The elevators in the building have buttons numbered 1 through 54. Count how many times the digit 5 appears on these buttons. | 10 | 1 54 1 [OP_LIST_ARANGE] [OP_LIST2NUM] [OP_NUM2LIST] 5 [OP_LIST_FIND_NUM] | var_a = 1
var_b = 54
var_c = 1
list_a = [i for i in range(var_a, var_b + 1, var_c)]
var_d=""
for i in list_a:
i = str(i)
var_d = var_d + i
list_b = []
var_d = int(var_d)
while var_d//10 > 0:
list_b.append(var_d%10)
var_d = var_d//10
list_b.append(var_d%10)
list_b = list_b[::-1]
var_e = 5
var_f = 0
var_e = int(var_e)
for i in list_b:
i = int(i)
if i == var_e:
var_f = var_f + 1
print(int(var_f)) |
Possibility | Find the number of ways to place one math book and one science book in a row on a bookshelf. | 2 | [OP_LIST_SOL] math science [OP_LIST_EOL] [OP_LIST_LEN] [OP_LIST_LEN] [OP_PERM] | var_a = 'math'
var_b = 'science'
list_a= []
if "/" in str(var_b):
var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_c = len(list_a)
var_d = len(list_a)
var_e = 1
var_c = int(var_c)
var_d = int(var_d)
for i, elem in enumerate(range(var_d)):
var_e = var_e * (var_c-i)
print(int(var_e)) |
Possibility | Among Jungkook, Jimin, Yoongi, and Yuna, we want to choose two people, including picking the same person. How many options are there in total? | 10 | [OP_LIST_SOL] Jungkook Jimin Yoongi Yuna [OP_LIST_EOL] [OP_LIST_LEN] 2 [OP_ADD] 1 [OP_SUB] 2 [OP_COMB] | var_a = 'Jungkook'
var_b = 'Jimin'
var_c = 'Yoongi'
var_d = 'Yuna'
list_a= []
if "/" in str(var_d):
var_d = eval(str(var_d))
list_a.append(var_d)
if "/" in str(var_c):
var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_e = len(list_a)
var_f = 2
var_g = var_e + var_f
var_h = 1
var_i = var_g - var_h
var_j = 2
var_k = 1
var_i = int(var_i)
var_j = int(var_j)
for i, elem in enumerate(range(var_j)):
var_k = var_k * (var_i-i)
for i, elem in enumerate(range(var_j)):
var_k = var_k / (i+1)
print(int(var_k)) |
Comparison | Yoongi collected 7, Jungkook 6, and Yuna 9. Who has the biggest number? | Yuna | [OP_LIST_SOL] Yoongi Jungkook Yuna [OP_LIST_EOL] [OP_LIST_SOL] 7 6 9 [OP_LIST_EOL] 1 [OP_LIST_MAX] [OP_LIST_INDEX] [OP_LIST_POP] [OP_LIST_GET] | var_a = 'Yoongi'
var_b = 'Jungkook'
var_c = 'Yuna'
list_a= []
if "/" in str(var_c):
var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_d = 7
var_e = 6
var_f = 9
list_b= []
if "/" in str(var_f):
var_f = eval(str(var_f))
list_b.append(var_f)
if "/" in str(var_e):
var_e = eval(str(var_e))
list_b.append(var_e)
if "/" in str(var_d):
var_d = eval(str(var_d))
list_b.append(var_d)
list_b.reverse()
var_g = 1
list_c=list_b.copy()
list_c.sort()
var_h = list_c[-var_g]
var_i = list_b.index(var_h)+1
var_j = list_a[var_i-1]
print(var_j) |
Correspondence | When you multiply a particular number by 6, you get 72. what is that number? | 12 | 72 6 [OP_DIV] | var_a = 72
var_b = 6
var_c = var_a / var_b
print(int(var_c)) |
Geometry | The Go stones are arranged regulary without gaps to form a square. If the number of stones on one side is 6, what is the number of Go stones are placed around the perimeter of the square? | 20 | 6 4 [OP_MUL] 4 [OP_SUB] | var_a = 6
var_b = 4
var_c = var_a * var_b
var_d = 4
var_e = var_c - var_d
print(int(var_e)) |
Arithmetic calculation | Mina is currently 200 meters (m) away from the finish line, and her friend, who is currently in the first place, is exactly halfway between Mina and the finish line. How many more meters (m) must the first-place friend run to reach the finish line? | 100 | 200 2 [OP_DIV] | var_a = 200
var_b = 2
var_c = var_a / var_b
print(int(var_c)) |
Correspondence | Dividing a number by 3 gives 10. Find the number. | 30 | 10 3 [OP_MUL] | var_a = 10
var_b = 3
var_c = var_a * var_b
print(int(var_c)) |
Comparison | 9 students stood in a line. How many students are standing between 7th from the right and 3rd from the right? | 3 | 7 3 [OP_SUB] 1 [OP_SUB] | var_a = 7
var_b = 3
var_c = var_a - var_b
var_d = 1
var_e = var_c - var_d
print(int(var_e)) |
Possibility | The red bag contains 3 balls with different numbers inscribed, and the blue bag contains 5 balls with different numbers inscribed. Find the number of ways Taemin picks one ball from each of the two pockets. | 15 | 3 1 [OP_COMB] 5 1 [OP_COMB] [OP_MUL] | var_a = 3
var_b = 1
var_c = 1
var_a = int(var_a)
var_b = int(var_b)
for i, elem in enumerate(range(var_b)):
var_c = var_c * (var_a-i)
for i, elem in enumerate(range(var_b)):
var_c = var_c / (i+1)
var_d = 5
var_e = 1
var_f = 1
var_d = int(var_d)
var_e = int(var_e)
for i, elem in enumerate(range(var_e)):
var_f = var_f * (var_d-i)
for i, elem in enumerate(range(var_e)):
var_f = var_f / (i+1)
var_g = var_c * var_f
print(int(var_g)) |
Arithmetic calculation | It is said that Geun-bae jump ropes twice as many times as he skipped the previous day. If Geun-bae did 15 times on the first day, find out how many times he will do it on the fourth day. | 120 | 15 2 4 1 [OP_SUB] [OP_POW] [OP_MUL] | var_a = 15
var_b = 2
var_c = 4
var_d = 1
var_e = var_c - var_d
var_f = var_b ** var_e
var_g = var_a * var_f
print(int(var_g)) |
Possibility | You want to create a five-digit number by using the digits 1, 6, and 9 allowing duplicates. How many two-digit numbers can you make? | 243 | [OP_LIST_SOL] 1 6 9 [OP_LIST_EOL] 5 [OP_LIST_GET_PRODUCT] [OP_LIST_LEN] | var_a = 1
var_b = 6
var_c = 9
list_a= []
if "/" in str(var_c):
var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_d = 5
list_b = [str(i) for i in list_a]
list_b = list(itertools.product(list_b, repeat=var_d))
list_b = [''.join(num_list) for num_list in list_b]
list_b = [str_num for str_num in list_b if str_num[0] != '0']
list_b = [float(i) for i in list_b]
var_e = len(list_b)
print(int(var_e)) |
Arithmetic calculation | Geon-wu and Jia turned in opposite directions at the circular playground and met each other. If the circumference of the field is 18 kilometers (km) and Geon-wu runs at 5 kilometers (km) per hour and Jia runs at 4 kilometers (km) per hour, how far did Gern-wu run? | 10 | 18 5 4 [OP_ADD] [OP_DIV] 5 [OP_MUL] | var_a = 18
var_b = 5
var_c = 4
var_d = var_b + var_c
var_e = var_a / var_d
var_f = 5
var_g = var_e * var_f
print(int(var_g)) |
Geometry | There is a polygon where only one diagonal can be drawn from a single vertex. How many edges does this polygon have? | 4 | 1 3 [OP_ADD] | var_a = 1
var_b = 3
var_c = var_a + var_b
print(int(var_c)) |
Arithmetic calculation | There are a total of 1500 students at Byul's School, 0.4 of which are male students. If 0.65 of the female students at Byul's School don't like PE, how many girls like PE? | 315 | 1500 1 0.4 [OP_SUB] [OP_MUL] 1 0.65 [OP_SUB] [OP_MUL] | var_a = 1500
var_b = 1
var_c = 0.4
var_d = var_b - var_c
var_e = var_a * var_d
var_f = 1
var_g = 0.65
var_h = var_f - var_g
var_i = var_e * var_h
print(int(var_i)) |
Possibility | The seven digits 0, 1, 2, 3, 4, 5, and 6 are used once to form a seven-digit number. If the number formed is a multiple of 55, find the largest number that can be made. | 6431205 | [OP_LIST_SOL] 0 1 2 3 4 5 6 [OP_LIST_EOL] 7 [OP_LIST_GET_PERM] 55 [OP_LIST_DIVISIBLE] 1 [OP_LIST_MAX] | var_a = 0
var_b = 1
var_c = 2
var_d = 3
var_e = 4
var_f = 5
var_g = 6
list_a= []
if "/" in str(var_g):
var_g = eval(str(var_g))
list_a.append(var_g)
if "/" in str(var_f):
var_f = eval(str(var_f))
list_a.append(var_f)
if "/" in str(var_e):
var_e = eval(str(var_e))
list_a.append(var_e)
if "/" in str(var_d):
var_d = eval(str(var_d))
list_a.append(var_d)
if "/" in str(var_c):
var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_h = 7
list_b = [str(i) for i in list_a]
list_b = list(itertools.permutations(list_b, var_h))
list_b = [''.join(num_list) for num_list in list_b]
list_b = [str_num for str_num in list_b if str_num[0] != '0']
list_b = [float(i) for i in list_b]
var_i = 55
list_c = []
var_i = int(var_i)
for i in list_b:
i = int(i)
if i % var_i == 0:
list_c.append(i)
var_j = 1
list_d=list_c.copy()
list_d.sort()
var_k = list_d[-var_j]
print(int(var_k)) |
Arithmetic calculation | The sum of 3 consecutive odd numbers is 28 greater than the largest number of the 3 odd numbers. Write the smallest of the three odd numbers. | 13 | 28 2 1 [OP_MUL] 2 2 [OP_MUL] [OP_ADD] [OP_ADD] 3 1 [OP_SUB] [OP_DIV] 2 2 [OP_MUL] [OP_SUB] | var_a = 28
var_b = 2
var_c = 1
var_d = var_b * var_c
var_e = 2
var_f = 2
var_g = var_e * var_f
var_h = var_d + var_g
var_i = var_a + var_h
var_j = 3
var_k = 1
var_l = var_j - var_k
var_m = var_i / var_l
var_n = 2
var_o = 2
var_p = var_n * var_o
var_q = var_m - var_p
print(int(var_q)) |
Arithmetic calculation | What is the sum of all even numbers from 1 to 200? | 10100 | 1 200 [OP_LIST_EVEN] [OP_LIST_SUM] | var_a = 1
var_b = 200
list_a = []
if var_a%2!=0:
for i in range(var_a+1, var_b+1, 2):
list_a.append(i)
else:
for i in range(var_a, var_b+1, 2):
list_a.append(i)
list_a = [float(i) for i in list_a]
var_c = sum(list_a)
print(int(var_c)) |
Possibility | How many natural numbers from 100 to 9999 are multiples of 25 and the sum of each digit is 17? | 24 | 100 9999 1 [OP_LIST_ARANGE] 25 [OP_LIST_DIVISIBLE] [OP_LIST_NUM2SUM] 17 [OP_LIST_FIND_NUM] | var_a = 100
var_b = 9999
var_c = 1
list_a = [i for i in range(var_a, var_b + 1, var_c)]
var_d = 25
list_b = []
var_d = int(var_d)
for i in list_a:
i = int(i)
if i % var_d == 0:
list_b.append(i)
list_c=[]
for i in list_b:
var_e = 0
i = int(i)
while i//10 > 0:
var_e = var_e + i%10
i = i//10
var_e = var_e + i%10
list_c.append(var_e)
var_f = 17
var_g = 0
var_f = int(var_f)
for i in list_c:
i = int(i)
if i == var_f:
var_g = var_g + 1
print(int(var_g)) |
Arithmetic calculation | There is a car that consumes 0.08 liters (l) of gasoline to travel 1 kilometer (km). Find the amount of gasoline consumed in liters (L) when this car traveled for 2 hours and 36 minutes at a speed of 80 kilometers (km) per hour. | 16.64 | 0.08 80 2 36 60 [OP_DIV] [OP_ADD] [OP_MUL] [OP_MUL] | var_a = 0.08
var_b = 80
var_c = 2
var_d = 36
var_e = 60
var_f = var_d / var_e
var_g = var_c + var_f
var_h = var_b * var_g
var_i = var_a * var_h
print('{:.2f}'.format(round(var_i+1e-10,2))) |
Geometry | You are going to make a hula hoop that is 14 centimeters (cm) in diameter. How many centimeters (cm) is the radius of the hula hoop? | 7 | 14 2 [OP_DIV] | var_a = 14
var_b = 2
var_c = var_a / var_b
print(int(var_c)) |
Correspondence | How many three-digit numbers are there that are divisible by 4 and have a 3 in the hundreds? | 25 | 3 100 [OP_MUL] 3 100 [OP_MUL] 99 [OP_ADD] 1 [OP_LIST_ARANGE] 4 [OP_LIST_DIVISIBLE] [OP_LIST_LEN] | var_a = 3
var_b = 100
var_c = var_a * var_b
var_d = 3
var_e = 100
var_f = var_d * var_e
var_g = 99
var_h = var_f + var_g
var_i = 1
list_a = [i for i in range(var_c, var_h + 1, var_i)]
var_j = 4
list_b = []
var_j = int(var_j)
for i in list_a:
i = int(i)
if i % var_j == 0:
list_b.append(i)
var_k = len(list_b)
print(int(var_k)) |
Geometry | There are 27 cubes with a side of 3 centimeters (cm). If you stack these cubes to make another cube, what is the surface area of the stacked cubes? | 486 | 3 27 1/3 [OP_POW] [OP_MUL] 2 [OP_POW] 6 [OP_MUL] | var_a = 3
var_b = 27
var_c = 0.3333333333333333
var_d = var_b ** var_c
var_e = var_a * var_d
var_f = 2
var_g = var_e ** var_f
var_h = 6
var_i = var_g * var_h
print(int(var_i)) |
Possibility | I would like to buy 2 kinds of fruit. If the fruits sold in the fruit shop are Apples, Peaches, Pears, and Melons, how many possible ways are there? | 6 | [OP_LIST_SOL] Apple Peach Pear Melon [OP_LIST_EOL] [OP_LIST_LEN] 2 [OP_COMB] | var_a = 'Apple'
var_b = 'Peach'
var_c = 'Pear'
var_d = 'Melon'
list_a= []
if "/" in str(var_d):
var_d = eval(str(var_d))
list_a.append(var_d)
if "/" in str(var_c):
var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_e = len(list_a)
var_f = 2
var_g = 1
var_e = int(var_e)
var_f = int(var_f)
for i, elem in enumerate(range(var_f)):
var_g = var_g * (var_e-i)
for i, elem in enumerate(range(var_f)):
var_g = var_g / (i+1)
print(int(var_g)) |
Comparison | Jihoon has 7.8 meters (m) of yarn, Dongjun has 6.9 meters (m), and Chowon has 7.2 meters (m). Find out who has the longest yarn length. | Jihoon | [OP_LIST_SOL] Jihoon Dongjun Chowon [OP_LIST_EOL] [OP_LIST_SOL] 7.8 6.9 7.2 [OP_LIST_EOL] 1 [OP_LIST_MAX] [OP_LIST_INDEX] [OP_LIST_POP] [OP_LIST_GET] | var_a = 'Jihoon'
var_b = 'Dongjun'
var_c = 'Chowon'
list_a= []
if "/" in str(var_c):
var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_d = 7.8
var_e = 6.9
var_f = 7.2
list_b= []
if "/" in str(var_f):
var_f = eval(str(var_f))
list_b.append(var_f)
if "/" in str(var_e):
var_e = eval(str(var_e))
list_b.append(var_e)
if "/" in str(var_d):
var_d = eval(str(var_d))
list_b.append(var_d)
list_b.reverse()
var_g = 1
list_c=list_b.copy()
list_c.sort()
var_h = list_c[-var_g]
var_i = list_b.index(var_h)+1
var_j = list_a[var_i-1]
print(var_j) |
Comparison | The total number of students in Jimin's class is 35. If Jimin is the 10th tallest student in the class, find how many students are shorter than Jimin. | 25 | 35 10 [OP_SUB] | var_a = 35
var_b = 10
var_c = var_a - var_b
print(int(var_c)) |
Comparison | There are 13 students in all. Hoseok stands 9th from the right and Minyoung stands 8th from the left. Find how many people are in between Hoseok and Minyoung. | 2 | 8 9 [OP_ADD] 13 [OP_SUB] 2 [OP_SUB] | var_a = 8
var_b = 9
var_c = var_a + var_b
var_d = 13
var_e = var_c - var_d
var_f = 2
var_g = var_e - var_f
print(int(var_g)) |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.