category
stringclasses
5 values
question
stringlengths
20
555
answer
stringlengths
1
20
solution_abst
stringlengths
1
287
solution_code
stringlengths
27
5.97k
Comparison
I sorted 2.23, 3.12, 9.434, and 2.453 in ascending order. What is the number that comes in the second?
2.45
[OP_LIST_SOL] 2.23 3.12 9.434 2.453 [OP_LIST_EOL] 2 [OP_LIST_MIN]
var_a = 2.23 var_b = 3.12 var_c = 9.434 var_d = 2.453 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=list_a.copy() list_b.sort() var_f = list_b[var_e-1] print('{:.2f}'.format(round(var_f+1e-10,2)))
Correspondence
There are four numbers A, B, C, and D. Find B from the four-digit addition formula, AB4C+17D8=5671.
9
AB4C+17D8=5671 B [OP_DIGIT_UNK_SOLVER]
var_a = 'AB4C+17D8=5671' 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
You want to cut a ribbon in pieces of 0.82 millimeters (mm) to make a ribbon loop. Make a loop with 53.73 millimeters (mm) of ribbon and find how many centimeters (cm) of ribbon are left.
0.04
53.73 0.82 [OP_MOD] 10 [OP_DIV]
var_a = 53.73 var_b = 0.82 var_c = var_a % var_b var_d = 10 var_e = var_c / var_d print('{:.2f}'.format(round(var_e+1e-10,2)))
Correspondence
What number must be in B to make A3+61B=695, where A3 and 61B are each two-digit number and three-digit number?
2
A3+61B=695 B [OP_DIGIT_UNK_SOLVER]
var_a = 'A3+61B=695' 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))
Possibility
Write down the number of three-digit numbers that can be made by choosing three cards from four cards written as 2, 4, 8, and 6.
24
[OP_LIST_SOL] 2 4 8 6 [OP_LIST_EOL] 3 [OP_LIST_GET_PERM] [OP_LIST_LEN]
var_a = 2 var_b = 4 var_c = 8 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 = 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 = len(list_b) print(int(var_f))
Arithmetic calculation
Yoojeong gave 8 of the marbles she had to Eunji, and there were 24 left. How many marbles did Yoojung have at first?
32
24 8 [OP_ADD]
var_a = 24 var_b = 8 var_c = var_a + var_b print(int(var_c))
Geometry
I painted some trapezoidal roofs. If the top side is 5 centimeters (cm), the bottom side is 9 centimeters (cm), and the area is 56 square cm (cm 2), what is the height in centimeters (cm) of this roof?
8
56 2 [OP_MUL] 5 9 [OP_ADD] [OP_DIV]
var_a = 56 var_b = 2 var_c = var_a * var_b var_d = 5 var_e = 9 var_f = var_d + var_e var_g = var_c / var_f print(int(var_g))
Correspondence
A is the number of 55 groups of 100 and 19 groups of 10. B is the number that jumps 5 times from 173 in an increment of 224. Find the value of A-B.
4397
100 55 [OP_MUL] 10 19 [OP_MUL] [OP_ADD] 173 224 5 [OP_MUL] [OP_ADD] [OP_SUB]
var_a = 100 var_b = 55 var_c = var_a * var_b var_d = 10 var_e = 19 var_f = var_d * var_e var_g = var_c + var_f var_h = 173 var_i = 224 var_j = 5 var_k = var_i * var_j var_l = var_h + var_k var_m = var_g - var_l print(int(var_m))
Comparison
What is the sum of all numbers greater than or equal to 0.4 among 0.8, 1/2, 0.9, and 1/3?
2.2
[OP_LIST_SOL] 0.8 1/2 0.9 1/3 [OP_LIST_EOL] 0.4 [OP_LIST_MORE_EQUAL] [OP_LIST_SUM]
var_a = 0.8 var_b = 0.5 var_c = 0.9 var_d = 0.3333333333333333 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 = 0.4 list_b = [] for i in list_a: if i >= var_e: list_b.append(i) list_b = [float(i) for i in list_b] var_f = sum(list_b) print('{:.2f}'.format(round(var_f+1e-10,2)))
Geometry
If the lengths of the two sides of a rectangle are 9 centimeters (cm) and 11 centimeters (cm), find the sum of the lengths of the four sides.
40
9 11 [OP_ADD] 2 [OP_MUL]
var_a = 9 var_b = 11 var_c = var_a + var_b var_d = 2 var_e = var_c * var_d print(int(var_e))
Geometry
How many times is the volume of a cube with a side length of 2 meters (m) bigger compared to the volume of a cube with a side length of 100 centimeters (cm)?
8
2 3 [OP_POW] 100 100 [OP_DIV] 3 [OP_POW] [OP_DIV]
var_a = 2 var_b = 3 var_c = var_a ** var_b var_d = 100 var_e = 100 var_f = var_d / var_e var_g = 3 var_h = var_f ** var_g var_i = var_c / var_h print(int(var_i))
Geometry
The perimeter of a square is equal to the perimeter of a regular hexagon with sides measuring 6 centimeters (cm). What is the length of one side of this square in centimeters (cm)?
9
6 6 [OP_MUL] 4 [OP_DIV]
var_a = 6 var_b = 6 var_c = var_a * var_b var_d = 4 var_e = var_c / var_d print(int(var_e))
Arithmetic calculation
I turned on the tap for 21 liters (L) for 6 minutes and received water in the bathtub that drained 0.3 liters (L) for 1 minute. If it took 22 minutes and 30 seconds to fill the bathtub, how many liters of water was in the bathtub at first?
72
21 6 [OP_DIV] 0.3 [OP_SUB] 22 30 60 [OP_DIV] [OP_ADD] [OP_MUL]
var_a = 21 var_b = 6 var_c = var_a / var_b var_d = 0.3 var_e = var_c - var_d var_f = 22 var_g = 30 var_h = 60 var_i = var_g / var_h var_j = var_f + var_i var_k = var_e * var_j print(int(var_k))
Arithmetic calculation
There are 5 times as many baseballs in the gym as there are soccer balls. And volleyballs has three times as much as soccer balls. The number of baseballs plus volleyballs is equal to160. Find the number of soccer balls.
20
160 5 3 [OP_ADD] [OP_DIV]
var_a = 160 var_b = 5 var_c = 3 var_d = var_b + var_c var_e = var_a / var_d print(int(var_e))
Correspondence
Rounding down 1A77 to the hundreds place gives 1700. Find A
7
1A77 [OP_GEN_POSSIBLE_LIST] 1700 [OP_LIST_MORE_EQUAL] 1700 100 [OP_ADD] [OP_LIST_LESS] 1A77 A [OP_LIST_FIND_UNK]
var_a = '1A77' 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 = 1700 list_b = [] for i in list_a: if i >= var_b: list_b.append(i) var_c = 1700 var_d = 100 var_e = var_c + var_d list_c = [] for i in list_b: if i < var_e: list_c.append(i) var_f = '1A77' var_g = 'A' var_f = str(var_f) var_g = str(var_g) unk_idx = var_f.index(var_g) var_h = 0 for elem in list_c: elem = str(elem) var_h = int(elem[unk_idx]) print(int(var_h))
Arithmetic calculation
There are four numbers 35, 68, 57, and 95. What is the difference between the second-largest number and the smallest number?
33
[OP_LIST_SOL] 35 68 57 95 [OP_LIST_EOL] 2 [OP_LIST_MAX] 1 [OP_LIST_MIN] [OP_SUB]
var_a = 35 var_b = 68 var_c = 57 var_d = 95 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=list_a.copy() list_b.sort() var_f = list_b[-var_e] var_g = 1 list_c=list_a.copy() list_c.sort() var_h = list_c[var_g-1] var_i = var_f - var_h print(int(var_i))
Arithmetic calculation
There are 500 customers in line in front of a store. If all customers get number tickets numbered from 1 to 500, how many times the number 4 is written on the number tickets?
200
1 500 1 [OP_LIST_ARANGE] [OP_LIST2NUM] [OP_NUM2LIST] 4 [OP_LIST_FIND_NUM]
var_a = 1 var_b = 500 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 = 4 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))
Correspondence
Taehyung wants to multiply a number by 8. But when he accidentally multiplied it by 5, the result came out as 30. Find the correct calculation result.
48
30 5 [OP_DIV] 8 [OP_MUL]
var_a = 30 var_b = 5 var_c = var_a / var_b var_d = 8 var_e = var_c * var_d print(int(var_e))
Correspondence
The box contains beads. When you distribute 65 marbles equally to 8 people from the box, there is no marbles left at the box. How many marbles will each person receive if all the marbles are equally distributed to 5 people?
104
65 8 [OP_MUL] 5 [OP_FDIV]
var_a = 65 var_b = 8 var_c = var_a * var_b var_d = 5 var_e = var_c // var_d print(int(var_e))
Correspondence
Calculate A when the two-digit addition equation AB+BC=BCB and A, B, and C are different numbers.
9
AB+BC=BCB A [OP_DIGIT_UNK_SOLVER]
var_a = 'AB+BC=BCB' 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))
Arithmetic calculation
I am going to attach 15 pieces of colored tape, every 20 centimeters (cm) in length, overlapping each other by 5 centimeters (cm) in a long line. Find the total length in centimeters (cm) of the 15 sheets of colored tape.
230
20 20 5 [OP_SUB] 15 1 [OP_SUB] [OP_MUL] [OP_ADD]
var_a = 20 var_b = 20 var_c = 5 var_d = var_b - var_c var_e = 15 var_f = 1 var_g = var_e - var_f var_h = var_d * var_g var_i = var_a + var_h print(int(var_i))
Geometry
How many square centimeters (cm2) is the area of a rhombus that can be drawn between the four sides of a square with a circumference of 96 centimeters (cm)?
288
96 4 [OP_DIV] 2 [OP_POW] 2 [OP_DIV]
var_a = 96 var_b = 4 var_c = var_a / var_b var_d = 2 var_e = var_c ** var_d var_f = 2 var_g = var_e / var_f print(int(var_g))
Arithmetic calculation
Her father bought 27 tangerines and gave 18 to Eunji. How many tangerines does the father have left?
9
27 18 [OP_SUB]
var_a = 27 var_b = 18 var_c = var_a - var_b print(int(var_c))
Geometry
How many edges does a pentagonal pyramid have?
10
5 2 [OP_MUL]
var_a = 5 var_b = 2 var_c = var_a * var_b print(int(var_c))
Geometry
Find the area of a parallelogram with base length 3 and height 3.
9
3 2 [OP_POW]
var_a = 3 var_b = 2 var_c = var_a ** var_b print(int(var_c))
Correspondence
You are going to add 24 to a specific number. If the answer when multiplied by 2 incorrectly is 50, what is the result of calculating correctly?
49
50 2 [OP_DIV] 24 [OP_ADD]
var_a = 50 var_b = 2 var_c = var_a / var_b var_d = 24 var_e = var_c + var_d print(int(var_e))
Correspondence
In Juwon's class, 7 out of 15 students brought colored paper, and the rest did not. 48 pieces of colored paper were distributed equally to students who did not bring any colored paper. Find how many sheets of colored paper were given to students.
6
48 15 7 [OP_SUB] [OP_DIV]
var_a = 48 var_b = 15 var_c = 7 var_d = var_b - var_c var_e = var_a / var_d print(int(var_e))
Possibility
There are 10 bags containing different colored pencils. If you draw 3 colored pencils from a bag, how many possible ways are there?
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))
Correspondence
There are two different numbers A and B. Find the sum of A and B that satisfy the multiplication equation of AB×6=BBB.
11
AB×6=BBB A [OP_DIGIT_UNK_SOLVER] AB×6=BBB B [OP_DIGIT_UNK_SOLVER] [OP_ADD]
var_a = 'AB×6=BBB' 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 = 'AB×6=BBB' 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))
Comparison
A is the quotient of 64 divided by 8 plus 27. B is the number of A divided by 7 times 5. Which number is smaller among A and B?
B
[OP_LIST_SOL] A B [OP_LIST_EOL] [OP_LIST_SOL] 64 8 [OP_DIV] 27 [OP_ADD] 64 8 [OP_DIV] 27 [OP_ADD] 7 [OP_DIV] 5 [OP_MUL] [OP_LIST_EOL] 1 [OP_LIST_MIN] [OP_LIST_INDEX] [OP_LIST_POP] [OP_LIST_GET]
var_a = 'A' var_b = 'B' 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 = 64 var_d = 8 var_e = var_c / var_d var_f = 27 var_g = var_e + var_f var_h = 64 var_i = 8 var_j = var_h / var_i var_k = 27 var_l = var_j + var_k var_m = 7 var_n = var_l / var_m var_o = 5 var_p = var_n * var_o list_b= [] if "/" in str(var_p): var_p = eval(str(var_p)) list_b.append(var_p) if "/" in str(var_g): var_g = eval(str(var_g)) list_b.append(var_g) list_b.reverse() var_q = 1 list_c=list_b.copy() list_c.sort() var_r = list_c[var_q-1] var_s = list_b.index(var_r)+1 var_t = list_a[var_s-1] print(var_t)
Arithmetic calculation
The older brother has 2800 won and the younger one has 1500 won. If the older brother gives some money to the younger brother, the older brother will have 360 won more than the younger brother. How much should the older brother give to the younger brother?
470
2800 1500 [OP_SUB] 360 [OP_SUB] 2 [OP_DIV]
var_a = 2800 var_b = 1500 var_c = var_a - var_b var_d = 360 var_e = var_c - var_d var_f = 2 var_g = var_e / var_f print(int(var_g))
Geometry
If you made a square by placing 10 square tiles on each vertical and horizontal line without gaps, how many tiles are placed at the perimeter?
36
10 4 [OP_MUL] 4 [OP_SUB]
var_a = 10 var_b = 4 var_c = var_a * var_b var_d = 4 var_e = var_c - var_d print(int(var_e))
Arithmetic calculation
194 students and 235 adults came to the amusement park, and 68 of them got free admission. Find how many more people who paid for admission to the amusement park than those who got in for free.
293
194 235 [OP_ADD] 68 [OP_SUB] 68 [OP_SUB]
var_a = 194 var_b = 235 var_c = var_a + var_b var_d = 68 var_e = var_c - var_d var_f = 68 var_g = var_e - var_f print(int(var_g))
Comparison
Junwoo is 1.63 meters (m) tall and Haeun is 1.58 meters (m) tall. Write the name of the taller person.
Junwoo
[OP_LIST_SOL] Junwoo Haeun [OP_LIST_EOL] [OP_LIST_SOL] 1.63 1.58 [OP_LIST_EOL] 1 [OP_LIST_MAX] [OP_LIST_INDEX] [OP_LIST_POP] [OP_LIST_GET]
var_a = 'Junwoo' var_b = 'Haeun' 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 = 1.63 var_d = 1.58 list_b= [] if "/" in str(var_d): var_d = eval(str(var_d)) list_b.append(var_d) if "/" in str(var_c): var_c = eval(str(var_c)) list_b.append(var_c) list_b.reverse() var_e = 1 list_c=list_b.copy() list_c.sort() var_f = list_c[-var_e] var_g = list_b.index(var_f)+1 var_h = list_a[var_g-1] print(var_h)
Correspondence
If you add a number to 55, the result is 88. What is the value of the number?
33
88 55 [OP_SUB]
var_a = 88 var_b = 55 var_c = var_a - var_b print(int(var_c))
Possibility
Minho is playing a game of using three number cards once to create the largest three-digit number and then find the difference between the two the third largest three-digit number. What is Minho's answer when he has the number cards 1, 6, and 8?
180
[OP_LIST_SOL] 1 6 8 [OP_LIST_EOL] [OP_LIST_LEN] [OP_LIST_GET_PERM] 1 [OP_LIST_MAX] 3 [OP_LIST_MAX] [OP_SUB]
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 = 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] var_g = 3 list_d=list_b.copy() list_d.sort() var_h = list_d[-var_g] var_i = var_f - var_h print(int(var_i))
Possibility
You want to create a six-digit number using 2, 0, 4, 1, 5, and 8 only once. What is the sum of the largest and smallest possible numbers?
956668
[OP_LIST_SOL] 2 0 4 1 5 8 [OP_LIST_EOL] 6 [OP_LIST_GET_PERM] 1 [OP_LIST_MAX] 1 [OP_LIST_MIN] [OP_ADD]
var_a = 2 var_b = 0 var_c = 4 var_d = 1 var_e = 5 var_f = 8 list_a= [] 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_g = 6 list_b = [str(i) for i in list_a] list_b = list(itertools.permutations(list_b, var_g)) 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_h = 1 list_c=list_b.copy() list_c.sort() var_i = list_c[-var_h] var_j = 1 list_d=list_b.copy() list_d.sort() var_k = list_d[var_j-1] var_l = var_i + var_k print(int(var_l))
Correspondence
There are two different natural numbers, A and B. When A is divided by 17, the quotient is 25 and the remainder is B. Find A when the remainder B is the largest.
441
25 17 [OP_MUL] 17 1 [OP_SUB] [OP_ADD]
var_a = 25 var_b = 17 var_c = var_a * var_b var_d = 17 var_e = 1 var_f = var_d - var_e var_g = var_c + var_f print(int(var_g))
Arithmetic calculation
The sum of 7 consecutive natural numbers is 63. Find the middle number.
9
63 0 7 1 [OP_SUB] 1 [OP_LIST_ARANGE] [OP_LIST_SUM] [OP_SUB] 7 [OP_DIV] 7 2 [OP_FDIV] [OP_ADD]
var_a = 63 var_b = 0 var_c = 7 var_d = 1 var_e = var_c - var_d var_f = 1 list_a = [i for i in range(var_b, var_e + 1, var_f)] list_a = [float(i) for i in list_a] var_g = sum(list_a) var_h = var_a - var_g var_i = 7 var_j = var_h / var_i var_k = 7 var_l = 2 var_m = var_k // var_l var_n = var_j + var_m print(int(var_n))
Geometry
Jungkook has 5 red balls, 4 blue balls, and 3 yellow balls. If Yoon-gi gives Jungkook 1 yellow ball, how many blue balls does Jungkook have?
4
4
var_a = 4 print(int(var_a))
Arithmetic calculation
What is the sum of all numbers that are divisible by 4 and 10 when you choose 3 cards with 1, 2, 4, and 0 written on them and use them all to make a three-digit number?
920
[OP_LIST_SOL] 1 2 4 0 [OP_LIST_EOL] 3 [OP_LIST_GET_PERM] 4 [OP_LIST_DIVISIBLE] 10 [OP_LIST_DIVISIBLE] [OP_LIST_SUM]
var_a = 1 var_b = 2 var_c = 4 var_d = 0 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 = 4 list_c = [] var_f = int(var_f) for i in list_b: i = int(i) if i % var_f == 0: list_c.append(i) var_g = 10 list_d = [] var_g = int(var_g) for i in list_c: i = int(i) if i % var_g == 0: list_d.append(i) list_d = [float(i) for i in list_d] var_h = sum(list_d) print(int(var_h))
Correspondence
When you add 7 to a number, you get 27. Divide a number by 5, then add 5 and multiply by 7. What is the result?
63
27 7 [OP_SUB] 5 [OP_DIV] 5 [OP_ADD] 7 [OP_MUL]
var_a = 27 var_b = 7 var_c = var_a - var_b var_d = 5 var_e = var_c / var_d var_f = 5 var_g = var_e + var_f var_h = 7 var_i = var_g * var_h print(int(var_i))
Comparison
Yoongi collected 7, Jungkook 6, and Yuna 9. Who has the smallest number?
Jungkook
[OP_LIST_SOL] Yoongi Jungkook Yuna [OP_LIST_EOL] [OP_LIST_SOL] 7 6 9 [OP_LIST_EOL] 1 [OP_LIST_MIN] [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-1] var_i = list_b.index(var_h)+1 var_j = list_a[var_i-1] print(var_j)
Arithmetic calculation
Junhyeok bought 7 apple boxes with 16 apples in each box, and Jihyun bought 6 apple boxes with 25 apples in each box. How many apples did Junhyeok and Jihyun buy?
262
16 7 [OP_MUL] 25 6 [OP_MUL] [OP_ADD]
var_a = 16 var_b = 7 var_c = var_a * var_b var_d = 25 var_e = 6 var_f = var_d * var_e var_g = var_c + var_f print(int(var_g))
Comparison
When 43.23, 2/5, and 21.23 are arranged in order from smallest to greatest, which number comes last?
43.23
[OP_LIST_SOL] 43.23 2 5 [OP_DIV] 21.23 [OP_LIST_EOL] [OP_LIST_LEN] [OP_LIST_MIN]
var_a = 43.23 var_b = 2 var_c = 5 var_d = var_b / var_c var_e = 21.23 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_a): var_a = eval(str(var_a)) list_a.append(var_a) list_a.reverse() var_f = len(list_a) list_b=list_a.copy() list_b.sort() var_g = list_b[var_f-1] print('{:.2f}'.format(round(var_g+1e-10,2)))
Geometry
You have a die with the sum of the number of eyes on one side and the number of eyes on the other side is 7. Given that the eyes on this die are 1 through 6, find the number of eyes on the opposite side of 5 multiplied by 5.
10
5 7 5 [OP_SUB] [OP_MUL]
var_a = 5 var_b = 7 var_c = 5 var_d = var_b - var_c var_e = var_a * var_d print(int(var_e))
Correspondence
Given that 3.A7>3.27 is true, how many digits from 0 to 9 can be written for A?
7
3.A7>3.27 A [OP_DIGIT_UNK_SOLVER] [OP_LIST_LEN]
var_a = '3.A7>3.27' 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] = [] 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].append(int(c[i])) list_a = list(set(ans_dict[var_b])) var_c = len(list_a) print(int(var_c))
Correspondence
There is a three-digit number A27 that can be made from a single-digit number A. Rounding down this number from the hundreds place gives 200. What is A?
2
A27 [OP_GEN_POSSIBLE_LIST] 200 [OP_LIST_MORE_EQUAL] 200 100 [OP_ADD] [OP_LIST_LESS] A [OP_LIST_FIND_UNK]
var_a = 'A27' 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 = 200 list_b = [] for i in list_a: if i >= var_b: list_b.append(i) var_c = 200 var_d = 100 var_e = var_c + var_d list_c = [] for i in list_b: if i < var_e: list_c.append(i) var_f = 'A' var_a = str(var_a) var_f = str(var_f) unk_idx = var_a.index(var_f) var_g = 0 for elem in list_c: elem = str(elem) var_g = int(elem[unk_idx]) print(int(var_g))
Comparison
Seokjin is standing right in front of Jimin. If Jimin is 9th from the front, what number is Seokjin?
8
9 1 [OP_SUB]
var_a = 9 var_b = 1 var_c = var_a - var_b print(int(var_c))
Arithmetic calculation
Apples are on sale in packs of 4 at the supermarket. If you buy 2 bunches, how many apples are there in total?
8
4 2 [OP_MUL]
var_a = 4 var_b = 2 var_c = var_a * var_b print(int(var_c))
Geometry
If a rectangle with an area of 36.48 square centimeters (cm2) has a width of 6.08 centimeters (cm), how many centimeters (cm) is its length?
6
36.48 6.08 [OP_DIV]
var_a = 36.48 var_b = 6.08 var_c = var_a / var_b print(int(eval('{:.2f}'.format(round(var_c+1e-10,2)))))
Correspondence
A is a single digit number. If you round down A76 in the hundreds place, you get a value of 700. What is A?
7
A76 [OP_GEN_POSSIBLE_LIST] 700 [OP_LIST_MORE_EQUAL] 700 100 [OP_ADD] [OP_LIST_LESS] A76 A [OP_LIST_FIND_UNK]
var_a = 'A76' 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 = 700 list_b = [] for i in list_a: if i >= var_b: list_b.append(i) var_c = 700 var_d = 100 var_e = var_c + var_d list_c = [] for i in list_b: if i < var_e: list_c.append(i) var_f = 'A76' var_g = 'A' var_f = str(var_f) var_g = str(var_g) unk_idx = var_f.index(var_g) var_h = 0 for elem in list_c: elem = str(elem) var_h = int(elem[unk_idx]) print(int(var_h))
Correspondence
A number that needs to be divided by 9/4, but multiplied by mistake, got 18/5. How much do you get when calculated correctly?
0.71
18/5 9/4 [OP_DIV] 9/4 [OP_DIV]
var_a = 3.6 var_b = 2.25 var_c = var_a / var_b var_d = 2.25 var_e = var_c / var_d print('{:.2f}'.format(round(var_e+1e-10,2)))
Arithmetic calculation
If there are 250 kilograms (kg) of carrots in the supermarket, and 2.5 times the weight of carrots is the weight of cucumbers, how many kilograms (kg) are there both carrots and cucumbers?
875
250 250 2.5 [OP_MUL] [OP_ADD]
var_a = 250 var_b = 250 var_c = 2.5 var_d = var_b * var_c var_e = var_a + var_d print(int(var_e))
Comparison
sunplant was planted in 2/7 of the flower garden, and snapweed was planted in 3/8. Which flowers are more widely planted?
snapweed
[OP_LIST_SOL] sunplant snapweed [OP_LIST_EOL] [OP_LIST_SOL] 2 7 [OP_DIV] 3 8 [OP_DIV] [OP_LIST_EOL] 1 [OP_LIST_MAX] [OP_LIST_INDEX] [OP_LIST_POP] [OP_LIST_GET]
var_a = 'sunplant' var_b = 'snapweed' 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 = 2 var_d = 7 var_e = var_c / var_d var_f = 3 var_g = 8 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 divided a number by 1.5 incorrectly, which was supposed to be divided by 6, the quotient is 3.8. Find the answer if you calculate correctly.
0.95
3.8 1.5 [OP_MUL] 6 [OP_DIV]
var_a = 3.8 var_b = 1.5 var_c = var_a * var_b var_d = 6 var_e = var_c / var_d print('{:.2f}'.format(round(var_e+1e-10,2)))
Possibility
How many different three-digit numbers can be formed using the three numbers 1, 2, and 7 once each?
6
[OP_LIST_SOL] 1 2 7 [OP_LIST_EOL] 3 [OP_LIST_GET_PERM] [OP_LIST_LEN]
var_a = 1 var_b = 2 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 = 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 = len(list_b) print(int(var_e))
Possibility
How many common multiples of 6 and 9 are found when you pick 3 of the natural number cards in sequence from 0 to 4 to form a 3-digit number?
4
[OP_LIST_SOL] 0 1 2 3 4 [OP_LIST_EOL] 3 [OP_LIST_GET_PERM] 6 9 [OP_LCM] [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.permutations(list_b, 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 = 6 var_h = 9 var_i = var_h * var_g / math.gcd(int(var_h), int(var_g)) 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 = len(list_c) print(int(var_j))
Possibility
Colored pencils of the same color cannot be distinguished. Find the number of ways to take out 2 colored pencils at a time when there are 2 or more colored pencils in each of red, blue, green, and purple.
6
4 3 [OP_MUL] 2 [OP_DIV]
var_a = 4 var_b = 3 var_c = var_a * var_b var_d = 2 var_e = var_c / var_d print(int(var_e))
Comparison
Friends lined up in a row. Seokjin stands 8th from the front and 6th from the back. How many friends are all in line?
13
8 6 [OP_ADD] 1 [OP_SUB]
var_a = 8 var_b = 6 var_c = var_a + var_b var_d = 1 var_e = var_c - var_d print(int(var_e))
Possibility
You are trying to create a three-digit number by choosing 3 of the 4 number cards 1, 3, 4, 7 and using them only once. How many numbers that are greater than or equal to 360 and less than or equal to 455 can be made?
6
[OP_LIST_SOL] 1 3 4 7 [OP_LIST_EOL] 3 [OP_LIST_GET_PERM] 360 [OP_LIST_MORE_EQUAL] 455 [OP_LIST_LESS_EQUAL] [OP_LIST_LEN]
var_a = 1 var_b = 3 var_c = 4 var_d = 7 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 = 360 list_c = [] for i in list_b: if i >= var_f: list_c.append(i) var_g = 455 list_d = [] for i in list_c: if i <= var_g: list_d.append(i) var_h = len(list_d) print(int(var_h))
Geometry
There is a cube in the shape of a cube, and the sum of the lengths of all its edges is 72 centimeters (cm). Find the length in centimeters (cm) of one edge of this cube.
6
72 4 3 [OP_MUL] [OP_DIV]
var_a = 72 var_b = 4 var_c = 3 var_d = var_b * var_c var_e = var_a / var_d print(int(var_e))
Possibility
When two of the number cards 3, 7, and 2 are used once to create the smallest two-digit number, which number is unused?
7
[OP_LIST_SOL] 3 7 2 [OP_LIST_EOL] 2 [OP_LIST_GET_PERM] 1 [OP_LIST_MIN] [OP_LIST_POP] [OP_NUM2LIST] [OP_SET_DIFFERENCE] 1 [OP_LIST_GET]
var_a = 3 var_b = 7 var_c = 2 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 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] list_d = [] var_f = int(var_f) while var_f//10 > 0: list_d.append(var_f%10) var_f = var_f//10 list_d.append(var_f%10) list_d = list_d[::-1] list_e = list(set(list_a) - set(list_d)) var_g = 1 var_h = list_e[var_g-1] print(int(var_h))
Correspondence
B is 278 plus 365 three times, and A is a number consisting of 20 bundles of 100 and 87 bundles of 10. Find A+B.
4243
100 20 [OP_MUL] 10 87 [OP_MUL] [OP_ADD] 278 365 3 [OP_MUL] [OP_ADD] [OP_ADD]
var_a = 100 var_b = 20 var_c = var_a * var_b var_d = 10 var_e = 87 var_f = var_d * var_e var_g = var_c + var_f var_h = 278 var_i = 365 var_j = 3 var_k = var_i * var_j var_l = var_h + var_k var_m = var_g + var_l print(int(var_m))
Geometry
After connecting 5 rice cakes with an original length of 2.7meters (m), overlapping each other by 0.3meters (m), cut them into 6 slices again to give them to the neighbors fairly. How much should I give?
2.05
2.7 5 [OP_MUL] 0.3 5 1 [OP_SUB] [OP_MUL] [OP_SUB] 6 [OP_DIV]
var_a = 2.7 var_b = 5 var_c = var_a * var_b var_d = 0.3 var_e = 5 var_f = 1 var_g = var_e - var_f var_h = var_d * var_g var_i = var_c - var_h var_j = 6 var_k = var_i / var_j print('{:.2f}'.format(round(var_k+1e-10,2)))
Arithmetic calculation
A 1000 milliliter (ml) bucket was filled with water, but there was a hole and water was leaking at a rate of 5 milliliters (ml) per minute. Find the time elapsed when 300 milliliters (ml) of water remain.
140
1000 300 [OP_SUB] 5 [OP_DIV]
var_a = 1000 var_b = 300 var_c = var_a - var_b var_d = 5 var_e = var_c / var_d print(int(var_e))
Possibility
When using 3 of the number cards 1, 4, 6, and 7 to make a 3-digit number, find the third smallest number with 1 in the tens place.
614
[OP_LIST_SOL] 1 4 6 7 [OP_LIST_EOL] 3 [OP_LIST_GET_PERM] 10 1 [OP_LIST_SEARCH_FIXED_DIGIT] 3 [OP_LIST_MIN]
var_a = 1 var_b = 4 var_c = 6 var_d = 7 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 = 10 var_g = 1 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 = 3 list_d=list_c.copy() list_d.sort() var_i = list_d[var_h-1] print(int(var_i))
Correspondence
When a certain number is divided by the number of students in Hyungjun's class, the quotient is 1.2, and when the number of students in Hyungjun's class is divided by the number of students in Jinmok's class, the quotient is 5/6. If you divide a certain number by the number of students in Jinmok's class, what is the quotient?
1
1.2 5/6 [OP_MUL]
var_a = 1.2 var_b = 0.8333333333333334 var_c = var_a * var_b print(int(var_c))
Geometry
In a rhombus with an area of 64/5 square centimeters (cm2), two non-adjacent vertices were selected and the distance was measured, which was 64/9 centimeters (cm). Find the distance between two unselected vertices.
3.6
64/5 2 [OP_MUL] 64/9 [OP_DIV]
var_a = 12.8 var_b = 2 var_c = var_a * var_b var_d = 7.111111111111111 var_e = var_c / var_d print('{:.2f}'.format(round(var_e+1e-10,2)))
Correspondence
When you add 10 to a particular number and divide it by 5, you get 4. Multiply that particular number by 3 and subtract 18. What is the value?
12
4 5 [OP_MUL] 10 [OP_SUB] 3 [OP_MUL] 18 [OP_SUB]
var_a = 4 var_b = 5 var_c = var_a * var_b var_d = 10 var_e = var_c - var_d var_f = 3 var_g = var_e * var_f var_h = 18 var_i = var_g - var_h print(int(var_i))
Possibility
How many four-digit numbers can be made by using the numbers written on cards 2, 5, 9, and 6, with using all the numbers once?
24
[OP_LIST_SOL] 2 5 9 6 [OP_LIST_EOL] 4 [OP_LIST_GET_PERM] [OP_LIST_LEN]
var_a = 2 var_b = 5 var_c = 9 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 = 4 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 = len(list_b) print(int(var_f))
Comparison
You want to divide 1 liter (L) of milk and 3 liters (L) of water equally into cups of the same shape and size. If 1 liter (L) of milk is divided equally into 2 A cups and 3 liters (L) of milk is divided equally into 4 B cups, which cup has more milk, Cup A or Cup B?
B
[OP_LIST_SOL] A B [OP_LIST_EOL] [OP_LIST_SOL] 1 2 [OP_MUL] 3 4 [OP_MUL] [OP_LIST_EOL] 1 [OP_LIST_MAX] [OP_LIST_INDEX] [OP_LIST_POP] [OP_LIST_GET]
var_a = 'A' var_b = 'B' 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 = 1 var_d = 2 var_e = var_c * var_d var_f = 3 var_g = 4 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)
Geometry
When trying to make a cube by stacking cuboid-shaped blocks with a width of 18 millimeters (mm), a length of 12 millimeters (mm), and a height of 9 millimeters (mm), find the minimum number of blocks required. (However, the height of the protruding part of the block is not considered.)
40310784
18 12 [OP_LCM] 9 [OP_LCM] 3 [OP_POW] 18 [OP_DIV] 18 12 [OP_LCM] 9 [OP_LCM] 12 [OP_DIV] 18 12 [OP_LCM] 9 [OP_LCM] 3 [OP_POW] 9 [OP_DIV] [OP_MUL] [OP_MUL]
var_a = 18 var_b = 12 var_c = var_b * var_a / math.gcd(int(var_b), int(var_a)) var_d = 9 var_e = var_d * var_c / math.gcd(int(var_d), int(var_c)) var_f = 3 var_g = var_e ** var_f var_h = 18 var_i = var_g / var_h var_j = 18 var_k = 12 var_l = var_k * var_j / math.gcd(int(var_k), int(var_j)) var_m = 9 var_n = var_m * var_l / math.gcd(int(var_m), int(var_l)) var_o = 12 var_p = var_n / var_o var_q = 18 var_r = 12 var_s = var_r * var_q / math.gcd(int(var_r), int(var_q)) var_t = 9 var_u = var_t * var_s / math.gcd(int(var_t), int(var_s)) var_v = 3 var_w = var_u ** var_v var_x = 9 var_y = var_w / var_x var_z = var_p * var_y var_A = var_i * var_z print(int(var_A))
Arithmetic calculation
How many natural numbers are 40 or greater and 70 or less?
31
70 40 [OP_SUB] 1 [OP_ADD]
var_a = 70 var_b = 40 var_c = var_a - var_b var_d = 1 var_e = var_c + var_d print(int(var_e))
Possibility
How many ways are there to stack up the sponges shaped in the alphabet A, B, and C in order?
6
[OP_LIST_SOL] A B C [OP_LIST_EOL] [OP_LIST_LEN] [OP_LIST_LEN] [OP_PERM]
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 = len(list_a) var_e = len(list_a) 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) print(int(var_f))
Geometry
The base of a parallelogram with an area of 48.6 square centimeters (cm2) is 5.4 centimeters (cm). What is the height of this figure?
9
48.6 5.4 [OP_DIV]
var_a = 48.6 var_b = 5.4 var_c = var_a / var_b print(int(var_c))
Geometry
Consider the area of the rhombus is 21.46 square centimeters (cm2) and the length of one diagonal is 7.4 centimeters (cm). Find the length of the other diagonal.
5.8
21.46 2 [OP_MUL] 7.4 [OP_DIV]
var_a = 21.46 var_b = 2 var_c = var_a * var_b var_d = 7.4 var_e = var_c / var_d print('{:.2f}'.format(round(var_e+1e-10,2)))
Possibility
Find the difference between the largest number and the smallest number using all number cards of 2, 4, 5, 1, 3, 7, 6, and 0 only once.
66308643
[OP_LIST_SOL] 2 4 5 1 3 7 6 0 [OP_LIST_EOL] [OP_LIST_LEN] [OP_LIST_GET_PERM] 1 [OP_LIST_MAX] 1 [OP_LIST_MIN] [OP_SUB]
var_a = 2 var_b = 4 var_c = 5 var_d = 1 var_e = 3 var_f = 7 var_g = 6 var_h = 0 list_a= [] if "/" in str(var_h): var_h = eval(str(var_h)) list_a.append(var_h) 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_i = len(list_a) list_b = [str(i) for i in list_a] list_b = list(itertools.permutations(list_b, var_i)) 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_j = 1 list_c=list_b.copy() list_c.sort() var_k = list_c[-var_j] var_l = 1 list_d=list_b.copy() list_d.sort() var_m = list_d[var_l-1] var_n = var_k - var_m print(int(var_n))
Arithmetic calculation
There are 5 vases. 4 vases have 5 flowers each, and the other one vase has 6 flowers. Find out the total amount of flowers in the vase.
26
4 5 [OP_MUL] 1 6 [OP_MUL] [OP_ADD]
var_a = 4 var_b = 5 var_c = var_a * var_b var_d = 1 var_e = 6 var_f = var_d * var_e var_g = var_c + var_f print(int(var_g))
Correspondence
A+C=15, A-B=1, C+C=A, B-D=2. If A, B, C, and D are different numbers, what should D be?
7
C+C+C=15 C [OP_NUM_UNK_SOLVER] 2 [OP_MUL] 1 [OP_SUB] 2 [OP_SUB]
var_a = 'C+C+C=15' var_b = 'C' 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] = 0 candidate_num = [i for i in range(51)] candi = list(itertools.product(candidate_num, 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)): if term_list[i] == '': new_eq += str(term_list[i])+op_list[i] else: new_eq += str(int(term_list[i]))+op_list[i] new_eq += str(int(term_list[-1])) new_eq=new_eq.replace('=', '==') new_eq=new_eq.replace('>==', '>=') new_eq=new_eq.replace('<==', '<=') eval_result = False try: if '=' in new_eq and '>' not in new_eq and '<' not in new_eq: new_eq=new_eq.replace('==','=') new_eq=new_eq.replace('>','') new_eq=new_eq.replace('<','') new_eq=new_eq.split('=') for i in range(len(new_eq)-1): eval_result = math.isclose(eval(new_eq[i]), eval(new_eq[i+1])) if not eval_result: break else: eval_result = eval(new_eq) except: eval_result = False 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 = 2 var_e = var_c * var_d var_f = 1 var_g = var_e - var_f var_h = 2 var_i = var_g - var_h print(int(var_i))
Arithmetic calculation
How many five-digit numbers are common multiples of 3 and 5?
6000
10000 99999 1 [OP_LIST_ARANGE] 3 [OP_LIST_DIVISIBLE] 5 [OP_LIST_DIVISIBLE] [OP_LIST_LEN]
var_a = 10000 var_b = 99999 var_c = 1 list_a = [i for i in range(var_a, var_b + 1, var_c)] var_d = 3 list_b = [] var_d = int(var_d) for i in list_a: i = int(i) if i % var_d == 0: list_b.append(i) var_e = 5 list_c = [] var_e = int(var_e) for i in list_b: i = int(i) if i % var_e == 0: list_c.append(i) var_f = len(list_c) print(int(var_f))
Comparison
Among the 30 students in Hoseok's class, 12 students came later than Hoseok. How many students came earlier than Hoseok?
17
30 12 [OP_SUB] 1 [OP_SUB]
var_a = 30 var_b = 12 var_c = var_a - var_b var_d = 1 var_e = var_c - var_d print(int(var_e))
Comparison
Seokjin is in the 5th row at the supermarket, and Namjoon is 6 people behind Seokjin. What's Namjoon's position?
11
5 6 [OP_ADD]
var_a = 5 var_b = 6 var_c = var_a + var_b print(int(var_c))
Correspondence
What will the result be if I multiply 10 by a certain number that becomes 0.735 when multiplied by 1/1000?
7350
0.735 1/1000 [OP_DIV] 10 [OP_MUL]
var_a = 0.735 var_b = 0.001 var_c = var_a / var_b var_d = 10 var_e = var_c * var_d print(int(var_e))
Comparison
There are 4 buses A, B, C and D. Bus A has more passengers than bus C, bus A has more passengers than bus B, and bus D has the fewest passengers. Which bus has the most passengers?
A
[OP_LIST_SOL] A B C D [OP_LIST_EOL] [OP_LIST_SOL] A B > A C > D A < D B < D C < [OP_LIST_EOL] [OP_LIST_COND_M(a)X_MIN] 1 [OP_LIST_GET]
var_a = 'A' var_b = 'B' var_c = 'C' var_d = 'D' 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 = 'A' var_f = 'B' var_g = '>' var_h = 'A' var_i = 'C' var_j = '>' var_k = 'D' var_l = 'A' var_m = '<' var_n = 'D' var_o = 'B' var_p = '<' var_q = 'D' var_r = 'C' var_s = '<' list_b= [] if "/" in str(var_s): var_s = eval(str(var_s)) list_b.append(var_s) if "/" in str(var_r): var_r = eval(str(var_r)) list_b.append(var_r) if "/" in str(var_q): var_q = eval(str(var_q)) list_b.append(var_q) if "/" in str(var_p): var_p = eval(str(var_p)) list_b.append(var_p) if "/" in str(var_o): var_o = eval(str(var_o)) list_b.append(var_o) if "/" in str(var_n): var_n = eval(str(var_n)) list_b.append(var_n) if "/" in str(var_m): var_m = eval(str(var_m)) list_b.append(var_m) if "/" in str(var_l): var_l = eval(str(var_l)) list_b.append(var_l) if "/" in str(var_k): var_k = eval(str(var_k)) list_b.append(var_k) if "/" in str(var_j): var_j = eval(str(var_j)) list_b.append(var_j) if "/" in str(var_i): var_i = eval(str(var_i)) list_b.append(var_i) 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) if "/" in str(var_e): var_e = eval(str(var_e)) list_b.append(var_e) list_b.reverse() var_t = '[OP_LIST_COND_M(a)X_MIN]' var_u = 1 var_v = list_b[var_u-1] print(var_v)
Arithmetic calculation
If the sum of three consecutive natural numbers is 30, what is the middle number among the three natural numbers?
10
30 0 3 1 [OP_SUB] 1 [OP_LIST_ARANGE] [OP_LIST_SUM] [OP_SUB] 3 [OP_DIV] 3 2 [OP_FDIV] [OP_ADD]
var_a = 30 var_b = 0 var_c = 3 var_d = 1 var_e = var_c - var_d var_f = 1 list_a = [i for i in range(var_b, var_e + 1, var_f)] list_a = [float(i) for i in list_a] var_g = sum(list_a) var_h = var_a - var_g 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 print(int(var_n))
Arithmetic calculation
A container with a capacity of 10 liters (l) is filled with water. From this container, you took the water out using a bowl of 1 liter (L) 500 milliliter (㎖) three times, and then again used a bowl of 1 liter (L) and 750 milliliters (㎖) once. After that, if you poured water out using a bowl of 1 liter (L) 250 milliliters (㎖), how many times did you pour it out using 1 liter (L) 250 milliliters (㎖) bowl to empty the container?
3
10 1000 [OP_MUL] 1 1000 [OP_MUL] 500 [OP_ADD] 3 [OP_MUL] [OP_SUB] 1 1000 [OP_MUL] 750 [OP_ADD] [OP_SUB] 1 1000 [OP_MUL] 250 [OP_ADD] [OP_DIV]
var_a = 10 var_b = 1000 var_c = var_a * var_b var_d = 1 var_e = 1000 var_f = var_d * var_e var_g = 500 var_h = var_f + var_g var_i = 3 var_j = var_h * var_i var_k = var_c - var_j var_l = 1 var_m = 1000 var_n = var_l * var_m var_o = 750 var_p = var_n + var_o var_q = var_k - var_p var_r = 1 var_s = 1000 var_t = var_r * var_s var_u = 250 var_v = var_t + var_u var_w = var_q / var_v print(int(var_w))
Arithmetic calculation
Minseok started watching the drama, yesterday he watched 1/3 of the total, and today he watched 2/5 of the total. Find how much of the whole is the unseen part.
0.27
1 1/3 [OP_SUB] 2/5 [OP_SUB]
var_a = 1 var_b = 0.3333333333333333 var_c = var_a - var_b var_d = 0.4 var_e = var_c - var_d print('{:.2f}'.format(round(var_e+1e-10,2)))
Arithmetic calculation
Taehyung entered the house third, and Seokjin entered the house immediately after. In what number did Seokjin enter?
4
3 1 [OP_ADD]
var_a = 3 var_b = 1 var_c = var_a + var_b print(int(var_c))
Correspondence
I mistakenly multiplied a number by 15, instead of multiplying it by 5, and I got 45. Find the result of the correct calculation.
15
45 15 [OP_DIV] 5 [OP_MUL]
var_a = 45 var_b = 15 var_c = var_a / var_b var_d = 5 var_e = var_c * var_d print(int(var_e))
Possibility
We are going to use 2 of our 3 number cards 1, 2, and 6 to create a two-digit number. Find the smallest possible multiple of 3.
12
[OP_LIST_SOL] 1 2 6 [OP_LIST_EOL] 2 [OP_LIST_GET_PERM] 3 [OP_LIST_DIVISIBLE] 1 [OP_LIST_MIN]
var_a = 1 var_b = 2 var_c = 6 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 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 = 3 list_c = [] var_e = int(var_e) for i in list_b: i = int(i) if i % var_e == 0: list_c.append(i) var_f = 1 list_d=list_c.copy() list_d.sort() var_g = list_d[var_f-1] print(int(var_g))
Arithmetic calculation
How many friends can you give 45 pieces of candy to if you give 5 pieces to each friend?
9
45 5 [OP_FDIV]
var_a = 45 var_b = 5 var_c = var_a // var_b print(int(var_c))
Arithmetic calculation
Seven azaleas are planted at equal intervals between two ginkgo trees that are 20 meters apart. If the distance between the ginkgo tree and the azalea is 1 meter (m), how many meters (m) is the distance between the azaleas?
2.5
20 7 1 [OP_ADD] [OP_DIV]
var_a = 20 var_b = 7 var_c = 1 var_d = var_b + var_c var_e = var_a / var_d print('{:.2f}'.format(round(var_e+1e-10,2)))
Geometry
A box in the shape of a cuboid has a volume of 315 square centimeters (cm2). If the width of this box is 9 centimeters (cm) and the vertical length is 7 centimeters (cm), what is the height of the box in centimeters (cm)?
5
315 9 [OP_DIV] 7 [OP_DIV]
var_a = 315 var_b = 9 var_c = var_a / var_b var_d = 7 var_e = var_c / var_d print(int(var_e))
Arithmetic calculation
The sum of five consecutive natural numbers is 60. Find the middle number.
12
60 0 5 1 [OP_SUB] 1 [OP_LIST_ARANGE] [OP_LIST_SUM] [OP_SUB] 5 [OP_DIV] 5 2 [OP_FDIV] [OP_ADD]
var_a = 60 var_b = 0 var_c = 5 var_d = 1 var_e = var_c - var_d var_f = 1 list_a = [i for i in range(var_b, var_e + 1, var_f)] list_a = [float(i) for i in list_a] var_g = sum(list_a) var_h = var_a - var_g var_i = 5 var_j = var_h / var_i var_k = 5 var_l = 2 var_m = var_k // var_l var_n = var_j + var_m print(int(var_n))
Comparison
Yoongi collected 4 apples, Jungkook collected 6 times 3 apples, and Yuna collected 5 apples. Who has the most apples?
Jungkook
[OP_LIST_SOL] Yoongi Jungkook Yuna [OP_LIST_EOL] [OP_LIST_SOL] 4 6 3 [OP_MUL] 5 [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 = 4 var_e = 6 var_f = 3 var_g = var_e * var_f 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_d): var_d = eval(str(var_d)) list_b.append(var_d) 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 triangle has an area of 576 square centimeters (cm2). If the base of this triangle is 32 centimeters (cm), how many centimeters (cm) is its height?
36
576 2 [OP_MUL] 32 [OP_DIV]
var_a = 576 var_b = 2 var_c = var_a * var_b var_d = 32 var_e = var_c / var_d print(int(var_e))
Correspondence
37 is 69 smaller than a number. What is the number that is 55 greater than the number?
161
69 37 [OP_ADD] 55 [OP_ADD]
var_a = 69 var_b = 37 var_c = var_a + var_b var_d = 55 var_e = var_c + var_d print(int(var_e))
Arithmetic calculation
You can make one mobile with 4 meters (m) of wire. How many mobiles of the same size can be made with 105.8 meters (m) of wire?
26
105.8 4 [OP_FDIV]
var_a = 105.8 var_b = 4 var_c = var_a // var_b print(int(var_c))
Correspondence
I need to add 39 to a number and subtract 44, but I made a mistake by adding 44 and subtracting 39, and I got 63. Find the result of the correct calculation.
53
63 44 [OP_SUB] 39 [OP_ADD] 39 [OP_ADD] 44 [OP_SUB]
var_a = 63 var_b = 44 var_c = var_a - var_b var_d = 39 var_e = var_c + var_d var_f = 39 var_g = var_e + var_f var_h = 44 var_i = var_g - var_h print(int(var_i))