category
stringclasses
5 values
question
stringlengths
20
555
answer
stringlengths
1
20
solution_abst
stringlengths
1
287
solution_code
stringlengths
27
5.97k
Arithmetic calculation
When you write the numbers from 10 to 99 in your notebook, how many times do you write the number 8?
19
10 99 1 [OP_LIST_ARANGE] [OP_LIST2NUM] [OP_NUM2LIST] 8 [OP_LIST_FIND_NUM]
var_a = 10 var_b = 99 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 = 8 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))
Comparison
Nine people stand in a line in order from shortest to tallest. Hoseok is the shortest, and there are 4 people standing between Yuna and Hoseok. If they line up again in order from tallest to shortest, what number will Yuna stand from the front?
4
9 1 [OP_SUB] 4 [OP_SUB] 1 [OP_SUB] 1 [OP_ADD]
var_a = 9 var_b = 1 var_c = var_a - var_b var_d = 4 var_e = var_c - var_d var_f = 1 var_g = var_e - var_f var_h = 1 var_i = var_g + var_h print(int(var_i))
Comparison
There are a total of 531 third and fourth graders attending an elementary school in Seoul. There are 31 more 4th graders than 3rd graders, and 22 fewer 3rd grade girls than 3rd grade boys. Among the boys attending this school, find how many are in the third grade.
136
531 31 [OP_SUB] 2 [OP_DIV] 22 [OP_SUB] 2 [OP_DIV] 22 [OP_ADD]
var_a = 531 var_b = 31 var_c = var_a - var_b var_d = 2 var_e = var_c / var_d var_f = 22 var_g = var_e - var_f var_h = 2 var_i = var_g / var_h var_j = 22 var_k = var_i + var_j print(int(var_k))
Arithmetic calculation
You want to place 6 flagpoles at regular intervals on a straight line that is 11.5 meters (m) long. How many meters (m) should be the distance between flagpoles?
2.3
11.5 6 1 [OP_SUB] [OP_DIV]
var_a = 11.5 var_b = 6 var_c = 1 var_d = var_b - var_c var_e = var_a / var_d print('{:.2f}'.format(round(var_e+1e-10,2)))
Correspondence
There is a three-digit number whose sum of each digit is 9 and is divisible by 5. How many of these three-digit numbers are there?
13
100 1000 1 [OP_SUB] 1 [OP_LIST_ARANGE] 5 [OP_LIST_DIVISIBLE] [OP_LIST_NUM2SUM] 9 [OP_LIST_FIND_NUM]
var_a = 100 var_b = 1000 var_c = 1 var_d = var_b - var_c var_e = 1 list_a = [i for i in range(var_a, var_d + 1, var_e)] var_f = 5 list_b = [] var_f = int(var_f) for i in list_a: i = int(i) if i % var_f == 0: list_b.append(i) list_c=[] for i in list_b: var_g = 0 i = int(i) while i//10 > 0: var_g = var_g + i%10 i = i//10 var_g = var_g + i%10 list_c.append(var_g) var_h = 9 var_i = 0 var_h = int(var_h) for i in list_c: i = int(i) if i == var_h: var_i = var_i + 1 print(int(var_i))
Possibility
How many three-digit integers can be made by drawing 3 out of 4 cards with the numbers 0, 4, 5, and 7 written on them?
18
4 3 [OP_PERM] 3 3 [OP_PERM] [OP_SUB]
var_a = 4 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) var_d = 3 var_e = 3 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) var_g = var_c - var_f print(int(var_g))
Correspondence
When a natural number A is divided by a natural number B, the quotient is 28 and the remainder is 4. Find the smallest A among all possible numbers that can be A.
144
5 28 [OP_MUL] 4 [OP_ADD]
var_a = 5 var_b = 28 var_c = var_a * var_b var_d = 4 var_e = var_c + var_d print(int(var_e))
Correspondence
There is a number that is greater than 50 and less than 70. This number has a remainder of 3 when divided by 5 and a remainder of 2 when divided by 7. What is this number?
58
50 70 1 [OP_SUB] 1 [OP_LIST_ARANGE] 5 3 [OP_LIST_DIVIDE_AND_REMAIN] 7 2 [OP_LIST_DIVIDE_AND_REMAIN] 1 [OP_LIST_GET]
var_a = 50 var_b = 70 var_c = 1 var_d = var_b - var_c var_e = 1 list_a = [i for i in range(var_a, var_d + 1, var_e)] var_f = 5 var_g = 3 list_b = [] var_f = int(var_f) var_g = int(var_g) if var_g < 0: var_g = var_g + var_f for i in list_a: i = int(i) if i%var_f == var_g: list_b.append(i) var_h = 7 var_i = 2 list_c = [] var_h = int(var_h) var_i = int(var_i) if var_i < 0: var_i = var_i + var_h for i in list_b: i = int(i) if i%var_h == var_i: list_c.append(i) var_j = 1 var_k = list_c[var_j-1] print(int(var_k))
Arithmetic calculation
A frog takes 5/18 minutes to jump 7/12 centimeters (cm). How many centimeters (cm) can this frog travel in 7 minutes if it runs at the same speed?
14.7
7/12 5/18 [OP_DIV] 7 [OP_MUL]
var_a = 0.5833333333333334 var_b = 0.2777777777777778 var_c = var_a / var_b var_d = 7 var_e = var_c * var_d print('{:.2f}'.format(round(var_e+1e-10,2)))
Possibility
There are 5 different interviewers. Find the number of cases in which two of them pass.
10
5 2 [OP_COMB]
var_a = 5 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))
Comparison
Among the five numbers 1.4, 9/10, 1.2, 0.5, 13/10, which number is at the very front, when numbers greater than or equal to 1.1 are picked up to be lined up in order from the smallest?
1.2
[OP_LIST_SOL] 1.4 9/10 1.2 0.5 13/10 [OP_LIST_EOL] 1.1 [OP_LIST_MORE_EQUAL] 1 [OP_LIST_MIN]
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-1] print('{:.2f}'.format(round(var_h+1e-10,2)))
Comparison
Taehyung read 32 pages of fairy tales yesterday, and today he read 13 fewer pages than yesterday. Namjoon read 25 pages of fairy tales yesterday, and today he read 14 more pages than yesterday. Who read more fairy tales yesterday and today combined?
Namjoon
[OP_LIST_SOL] Taehyung Namjoon [OP_LIST_EOL] [OP_LIST_SOL] 32 13 [OP_SUB] 32 [OP_ADD] 25 14 [OP_ADD] 25 [OP_ADD] [OP_LIST_EOL] 1 [OP_LIST_MAX] [OP_LIST_INDEX] [OP_LIST_POP] [OP_LIST_GET]
var_a = 'Taehyung' var_b = 'Namjoon' 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 = 32 var_d = 13 var_e = var_c - var_d var_f = 32 var_g = var_e + var_f var_h = 25 var_i = 14 var_j = var_h + var_i var_k = 25 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) 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
Jae-woong and Dong-hun started at the same place in opposite directions on a kickboard on a 3-kilometer (km)-long playground. If Jaewoong rides a kickboard at a speed of 100 meters (m) per minute and Donghun rides a kickboard at a speed of 150 meters (m) per minute, find out how many minutes later they will meet again for the first time.
12
3 100 1000 [OP_DIV] 150 1000 [OP_DIV] [OP_ADD] [OP_DIV]
var_a = 3 var_b = 100 var_c = 1000 var_d = var_b / var_c var_e = 150 var_f = 1000 var_g = var_e / var_f var_h = var_d + var_g var_i = var_a / var_h print(int(var_i))
Possibility
If the number of ways to get from point A to point B is 3 and from point B to point C is 4, find how many possible ways are there to get from point A to point C via point B.
12
3 4 [OP_MUL]
var_a = 3 var_b = 4 var_c = var_a * var_b print(int(var_c))
Geometry
When square-shaped tiles were laid in order to form a large square, 36 tiles were not used. I increased the width and length of the large square by one line each, and there were still 3 residual tiles left. How many tiles did I have?
292
36 3 [OP_SUB] 1 [OP_SUB] 2 [OP_DIV] 2 [OP_POW] 36 [OP_ADD]
var_a = 36 var_b = 3 var_c = var_a - var_b var_d = 1 var_e = var_c - var_d var_f = 2 var_g = var_e / var_f var_h = 2 var_i = var_g ** var_h var_j = 36 var_k = var_i + var_j print(int(var_k))
Possibility
You want to create a three-digit number using each 0, 2, 4, and 6 only once. Find the product of the largest possible number and the smallest possible number.
130968
[OP_LIST_SOL] 0 2 4 6 [OP_LIST_EOL] 3 [OP_LIST_GET_PERM] 1 [OP_LIST_MAX] 1 [OP_LIST_MIN] [OP_MUL]
var_a = 0 var_b = 2 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 = 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 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))
Geometry
If the area of a triangle when halved is in 7 square centimeters (cm2), what is the area before halving?
14
7 2 [OP_MUL]
var_a = 7 var_b = 2 var_c = var_a * var_b print(int(var_c))
Comparison
The number of flowers planted in each column is the same. When a rose is planted in the 9th column from the left, the 7th row from the front, the 16th row from the back, and the 13th column from the right, how many flowers are planted?
462
7 16 [OP_ADD] 1 [OP_SUB] 9 13 [OP_ADD] 1 [OP_SUB] [OP_MUL]
var_a = 7 var_b = 16 var_c = var_a + var_b var_d = 1 var_e = var_c - var_d var_f = 9 var_g = 13 var_h = var_f + var_g var_i = 1 var_j = var_h - var_i var_k = var_e * var_j print(int(var_k))
Arithmetic calculation
There are five numbers 10, 11, 12, 13, and 14. What is the product of the 3rd smallest number and the 2nd smallest number?
132
[OP_LIST_SOL] 10 11 12 13 14 [OP_LIST_EOL] 3 [OP_LIST_MIN] 2 [OP_LIST_MIN] [OP_MUL]
var_a = 10 var_b = 11 var_c = 12 var_d = 13 var_e = 14 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=list_a.copy() list_b.sort() var_g = list_b[var_f-1] var_h = 2 list_c=list_a.copy() list_c.sort() var_i = list_c[var_h-1] var_j = var_g * var_i print(int(var_j))
Arithmetic calculation
When Woo-jun's age is 1 year less than 1/4 of his mother's age and his mother's age is 5 years less than 5 times Woo-jun's age, how old is Woo-jun now?
9
1/4 5 [OP_MUL] 1 [OP_ADD] 1/4 5 [OP_MUL] 1 [OP_SUB] [OP_DIV]
var_a = 0.25 var_b = 5 var_c = var_a * var_b var_d = 1 var_e = var_c + var_d var_f = 0.25 var_g = 5 var_h = var_f * var_g var_i = 1 var_j = var_h - var_i var_k = var_e / var_j print(int(var_k))
Correspondence
For the natural numbers A, B, and C, when A is divided by 8, the quotient is B and the remainder is C. If the quotient and the remainder are equal, find the largest number of A.
63
8 8 1 [OP_SUB] [OP_MUL] 8 1 [OP_SUB] [OP_ADD]
var_a = 8 var_b = 8 var_c = 1 var_d = var_b - var_c var_e = var_a * var_d var_f = 8 var_g = 1 var_h = var_f - var_g var_i = var_e + var_h print(int(var_i))
Arithmetic calculation
The length of tape A which is equal to the length of the tape B folded in half is 35 centimeters (cm). The length of tape C is 21 centimeters (cm) longer than twice the length of tape A, how many centimeters (cm) is the sum of the lengths of tape B and tape C?
119
35 2 [OP_MUL] 35 2 [OP_MUL] 21 [OP_SUB] [OP_ADD]
var_a = 35 var_b = 2 var_c = var_a * var_b var_d = 35 var_e = 2 var_f = var_d * var_e var_g = 21 var_h = var_f - var_g var_i = var_c + var_h print(int(var_i))
Geometry
How many faces does a tetrahedron have?
4
4
var_a = 4 print(int(var_a))
Geometry
Suzy has a regular hexagon shaped piece of colored paper. The length of one side of this regular hexagon is 5 centimeters (cm). Find the circumference of this colored paper.
30
5 6 [OP_MUL]
var_a = 5 var_b = 6 var_c = var_a * var_b print(int(var_c))
Geometry
A box measuring 1 meter (m) in width, length, and height is stored on a rectangular piece of land measuring 44 meters (m) wide and 35 meters (m) long. If you stacked boxes in 7 layers on the first day and boxes in 3 layers on the second day, how many boxes did you get in two days?
15400
44 35 [OP_MUL] 7 3 [OP_ADD] [OP_MUL]
var_a = 44 var_b = 35 var_c = var_a * var_b var_d = 7 var_e = 3 var_f = var_d + var_e var_g = var_c * var_f print(int(var_g))
Geometry
When I measured the length of one side of a square-shaped blackboard, it was 6 centimeters (cm). What is the area of this blackboard in square centimeters (cm2)?
36
6 2 [OP_POW]
var_a = 6 var_b = 2 var_c = var_a ** var_b print(int(var_c))
Comparison
There are 60 consecutive natural numbers between 200 and this number. If the number is less than 200, how many numbers between 200 and the number are divisible by 2 and 3?
10
200 1 [OP_ADD] 60 [OP_SUB] 200 1 [OP_SUB] 1 [OP_LIST_ARANGE] 2 [OP_LIST_DIVISIBLE] 3 [OP_LIST_DIVISIBLE] [OP_LIST_LEN]
var_a = 200 var_b = 1 var_c = var_a + var_b var_d = 60 var_e = var_c - var_d var_f = 200 var_g = 1 var_h = var_f - var_g var_i = 1 list_a = [i for i in range(var_e, var_h + 1, var_i)] var_j = 2 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 = 3 list_c = [] var_k = int(var_k) for i in list_b: i = int(i) if i % var_k == 0: list_c.append(i) var_l = len(list_c) print(int(var_l))
Arithmetic calculation
If you cut and used 105 millimeters (mm) from a 23.3 centimeter (cm) wire and another 4.6 centimeters (cm) the next day, how many millimeters (mm) of wire are left?
82
23.3 10 [OP_MUL] 105 [OP_SUB] 4.6 10 [OP_MUL] [OP_SUB]
var_a = 23.3 var_b = 10 var_c = var_a * var_b var_d = 105 var_e = var_c - var_d var_f = 4.6 var_g = 10 var_h = var_f * var_g var_i = var_e - var_h print(int(var_i))
Geometry
What is the volume, in cubic centimeters (cm3), of a cube with an edge of 7 centimeters (cm)?
343
7 3 [OP_POW]
var_a = 7 var_b = 3 var_c = var_a ** var_b print(int(var_c))
Geometry
A pyramid has N bases. How much is N?
1
1
var_a = 1 print(int(var_a))
Geometry
The area of a trapezoid with an upper side that is 3.4 centimeters (cm) longer than the lower side and with a height of 5.2 centimeters (cm) is 100.62 square centimeters (cm2). How many centimeters (cm) is the length of the lower side?
17.65
100.62 2 [OP_MUL] 5.2 [OP_DIV] 3.4 [OP_SUB] 2 [OP_DIV]
var_a = 100.62 var_b = 2 var_c = var_a * var_b var_d = 5.2 var_e = var_c / var_d var_f = 3.4 var_g = var_e - var_f var_h = 2 var_i = var_g / var_h print('{:.2f}'.format(round(var_i+1e-10,2)))
Geometry
There is a box in the shape of a cuboid measuring 30 centimeters (cm) wide, 20 centimeters (cm) long, and 5 centimeters (cm) high. If this box contains all the chocolates in the shape of a cuboid measuring 6 centimeters (cm) wide, 4 centimeters (cm) long, and 1 cm (cm high) without leaving any space, how many chocolates are in the box?
125
30 20 [OP_MUL] 5 [OP_MUL] 6 4 [OP_MUL] 1 [OP_MUL] [OP_DIV]
var_a = 30 var_b = 20 var_c = var_a * var_b var_d = 5 var_e = var_c * var_d var_f = 6 var_g = 4 var_h = var_f * var_g var_i = 1 var_j = var_h * var_i var_k = var_e / var_j print(int(var_k))
Correspondence
A number divided by 9 and by 7 is 13. Find this number.
819
13 7 [OP_MUL] 9 [OP_MUL]
var_a = 13 var_b = 7 var_c = var_a * var_b var_d = 9 var_e = var_c * var_d print(int(var_e))
Arithmetic calculation
I put 30 tangerines, each weighing 0.36 kilograms (kg), in a gift box. At this moment, the weight of the gift box was 11.26 kilograms (kg). How many kilograms (kg) does an empty gift box weigh?
0.46
11.26 0.36 30 [OP_MUL] [OP_SUB]
var_a = 11.26 var_b = 0.36 var_c = 30 var_d = var_b * var_c var_e = var_a - var_d print('{:.2f}'.format(round(var_e+1e-10,2)))
Geometry
Mijeong's cuboid box has a bottom area of 14 square centimeters (cm2) and a height of 13 centimeters (cm). Find the volume of this box.
182
14 13 [OP_MUL]
var_a = 14 var_b = 13 var_c = var_a * var_b print(int(var_c))
Correspondence
While Yoongi was subtracting 57 from the two-digit number, he mistook the two-digit units digit 9 for 6. When the difference obtained by Yoongi is 39, what is the two-digit number?
99
39 57 [OP_ADD] 6 9 [OP_SUB] [OP_SUB]
var_a = 39 var_b = 57 var_c = var_a + var_b var_d = 6 var_e = 9 var_f = var_d - var_e var_g = var_c - var_f print(int(var_g))
Arithmetic calculation
What is the second largest odd number from 1 to 9?
7
1 9 [OP_LIST_ODD] 2 [OP_LIST_MAX]
var_a = 1 var_b = 9 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) var_c = 2 list_b=list_a.copy() list_b.sort() var_d = list_b[-var_c] print(int(var_d))
Arithmetic calculation
The average height of 11 members of the Yeonju's line is 145.7 centimeters (cm). However, if the heights of the two students are equal to 142.1 centimeters (cm), find the average of the heights of the other students.
146.5
145.7 11 [OP_MUL] 142.1 2 [OP_MUL] [OP_SUB] 11 2 [OP_SUB] [OP_DIV]
var_a = 145.7 var_b = 11 var_c = var_a * var_b var_d = 142.1 var_e = 2 var_f = var_d * var_e var_g = var_c - var_f var_h = 11 var_i = 2 var_j = var_h - var_i var_k = var_g / var_j print('{:.2f}'.format(round(var_k+1e-10,2)))
Arithmetic calculation
Jimin has 41 pieces of colored paper, and Seokjin has 1 less than Jimin. How many pieces of colored paper does Seokjin have?
40
41 1 [OP_SUB]
var_a = 41 var_b = 1 var_c = var_a - var_b print(int(var_c))
Possibility
There are 1 red ball, 1 yellow ball, and 2 blue balls. Given that balls of the same color are indistinguishable from each other, how many different ways can you arrange them differently?
12
1 1 [OP_ADD] 2 [OP_ADD] 1 1 [OP_ADD] 2 [OP_ADD] [OP_PERM] 2 2 [OP_PERM] [OP_DIV]
var_a = 1 var_b = 1 var_c = var_a + var_b var_d = 2 var_e = var_c + var_d var_f = 1 var_g = 1 var_h = var_f + var_g var_i = 2 var_j = var_h + var_i var_k = 1 var_e = int(var_e) var_j = int(var_j) for i, elem in enumerate(range(var_j)): var_k = var_k * (var_e-i) var_l = 2 var_m = 2 var_n = 1 var_l = int(var_l) var_m = int(var_m) for i, elem in enumerate(range(var_m)): var_n = var_n * (var_l-i) var_o = var_k / var_n print(int(var_o))
Correspondence
When a number A is divided by 8, the quotient and remainder are B and C, respectively. A, B, and C are natural numbers. If the quotient and the remainder are equal, find the largest number of A.
63
8 8 1 [OP_SUB] [OP_MUL] 8 1 [OP_SUB] [OP_ADD]
var_a = 8 var_b = 8 var_c = 1 var_d = var_b - var_c var_e = var_a * var_d var_f = 8 var_g = 1 var_h = var_f - var_g var_i = var_e + var_h print(int(var_i))
Arithmetic calculation
There are three tapes: tapes A, B, and C. The length of the tape A is 35 centimeters (cm). The length of tape A is half the length of tape B, and the length of tape C is 21 centimeters (cm) less than twice the length of tape A. What is the sum of the lengths of tape B and tape C in centimeters (cm)?
119
35 2 [OP_MUL] 35 2 [OP_MUL] 21 [OP_SUB] [OP_ADD]
var_a = 35 var_b = 2 var_c = var_a * var_b var_d = 35 var_e = 2 var_f = var_d * var_e var_g = 21 var_h = var_f - var_g var_i = var_c + var_h print(int(var_i))
Arithmetic calculation
You want to install 24 power poles with equal space between two poles on one side of a 239.66 meters (m) long road. If you are to install one at the beginning and one at the end of the road, how long should the distance between the power poles be in meters (m)?
10.42
239.66 24 1 [OP_SUB] [OP_DIV]
var_a = 239.66 var_b = 24 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
How many circles with a radius of 4 centimeters (cm) can be drawn in a rectangle with a width of 24 centimeters (cm) and a length of 8 centimeters (cm) without overlapping?
3
24 4 2 [OP_MUL] [OP_DIV]
var_a = 24 var_b = 4 var_c = 2 var_d = var_b * var_c var_e = var_a / var_d print(int(var_e))
Arithmetic calculation
(A) classmates planted 8 trees. (B) classmates planted 7 trees. How many trees did the students in class (A) and (B) plant?
15
8 7 [OP_ADD]
var_a = 8 var_b = 7 var_c = var_a + var_b print(int(var_c))
Possibility
Donghyun can put the magnets with 1, 6, and 8 written on them in the hundreds, tens, and ones place, respectively. What is the difference between the second largest and the third smallest number Donghyun can make?
198
[OP_LIST_SOL] 1 6 8 [OP_LIST_EOL] 3 [OP_LIST_GET_PERM] 2 [OP_LIST_MAX] 3 [OP_LIST_MIN] [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 = 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 list_d=list_b.copy() list_d.sort() var_h = list_d[var_g-1] var_i = var_f - var_h print(int(var_i))
Comparison
There are five shapes: triangular-prism, quadrangular-prism, triangular-pyramid, quadrangular-pyramid, and square-frustum. If each shape's face is colored with a different color, which shape needs the fewest colors?
triangular-pyramid
[OP_LIST_SOL] triangular-prism quadrangular-prism triangular-pyramid quadrangular-pyramid square-frustum [OP_LIST_EOL] [OP_LIST_SOL] 3 2 [OP_ADD] 4 2 [OP_ADD] 3 1 [OP_ADD] 4 1 [OP_ADD] 4 2 [OP_ADD] [OP_LIST_EOL] 1 [OP_LIST_MIN] [OP_LIST_INDEX] [OP_LIST_POP] [OP_LIST_GET]
var_a = 'triangular-prism' var_b = 'quadrangular-prism' var_c = 'triangular-pyramid' var_d = 'quadrangular-pyramid' var_e = 'square-frustum' 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 var_g = 2 var_h = var_f + var_g var_i = 4 var_j = 2 var_k = var_i + var_j var_l = 3 var_m = 1 var_n = var_l + var_m var_o = 4 var_p = 1 var_q = var_o + var_p var_r = 4 var_s = 2 var_t = var_r + var_s list_b= [] if "/" in str(var_t): var_t = eval(str(var_t)) list_b.append(var_t) if "/" in str(var_q): var_q = eval(str(var_q)) list_b.append(var_q) if "/" in str(var_n): var_n = eval(str(var_n)) list_b.append(var_n) if "/" in str(var_k): var_k = eval(str(var_k)) list_b.append(var_k) if "/" in str(var_h): var_h = eval(str(var_h)) list_b.append(var_h) list_b.reverse() var_u = 1 list_c=list_b.copy() list_c.sort() var_v = list_c[var_u-1] var_w = list_b.index(var_v)+1 var_x = list_a[var_w-1] print(var_x)
Correspondence
Seonghyeon and Jisoo are standing on the playground. Seonghyeon ran 200 meters (m) in the direction of Ji-soo and then ran 1000 meters (m) in the opposite direction. If the distance between Seonghyeon and Jisoo is now 2000 meters (m), find the distance in meters (m) between Seonghyeon and Jisoo before Seonghyeon moved.
1200
2000 1000 [OP_SUB] 200 [OP_ADD]
var_a = 2000 var_b = 1000 var_c = var_a - var_b var_d = 200 var_e = var_c + var_d print(int(var_e))
Possibility
Jungkook wants to buy different fruits and present them to Jimin and Yoongi. If the fruits sold at the fruit shop are apples, peaches, pears, melons, and strawberries, how many numbers of cases are possible for the gift?
20
[OP_LIST_SOL] apples peaches pears melons strawberries [OP_LIST_EOL] [OP_LIST_LEN] 2 [OP_PERM]
var_a = 'apples' var_b = 'peaches' var_c = 'pears' var_d = 'melons' var_e = 'strawberries' 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 = len(list_a) var_g = 2 var_h = 1 var_f = int(var_f) var_g = int(var_g) for i, elem in enumerate(range(var_g)): var_h = var_h * (var_f-i) print(int(var_h))
Possibility
How many three-digit numbers can be made by using all three numbers 1, 2, and 3 once?
6
[OP_LIST_SOL] 1 2 3 [OP_LIST_EOL] 3 [OP_LIST_GET_PERM] [OP_LIST_LEN]
var_a = 1 var_b = 2 var_c = 3 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))
Correspondence
When a number is divided by 7, the quotient is 13 and the remainder is 1. Add 9 to this number. Then, divide it by 8 to find the sum of the quotient and remainder.
17
13 7 [OP_MUL] 1 [OP_ADD] 9 [OP_ADD] 8 [OP_FDIV] 13 7 [OP_MUL] 1 [OP_ADD] 9 [OP_ADD] 8 [OP_MOD] [OP_ADD]
var_a = 13 var_b = 7 var_c = var_a * var_b var_d = 1 var_e = var_c + var_d var_f = 9 var_g = var_e + var_f var_h = 8 var_i = var_g // var_h var_j = 13 var_k = 7 var_l = var_j * var_k var_m = 1 var_n = var_l + var_m var_o = 9 var_p = var_n + var_o var_q = 8 var_r = var_p % var_q var_s = var_i + var_r print(int(var_s))
Geometry
A large track in the shape of a square with a side of 20 meters (m) was divided into 3 equal parts to create 3 smaller tracks. What is the area of this small track in square meters (m2)?
44.44
20 3 [OP_DIV] 2 [OP_POW]
var_a = 20 var_b = 3 var_c = var_a / var_b var_d = 2 var_e = var_c ** var_d print('{:.2f}'.format(round(var_e+1e-10,2)))
Geometry
How many edges does a regular icosahedron have?
30
30
var_a = 30 print(int(var_a))
Comparison
What is the sum of numbers which are greater than or equal to 1.1 among five numbers 1.4, 9/10, 1.2, 0.5, and 13/10.
3.9
[OP_LIST_SOL] 1.4 9/10 1.2 0.5 13/10 [OP_LIST_EOL] 1.1 [OP_LIST_MORE_EQUAL] [OP_LIST_SUM]
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) list_b = [float(i) for i in list_b] var_g = sum(list_b) print('{:.2f}'.format(round(var_g+1e-10,2)))
Correspondence
What number must go in A to make A7B+23=695?
6
A7B+23=695 A [OP_DIGIT_UNK_SOLVER]
var_a = 'A7B+23=695' 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
There are 15 chickens - 3 are hens and the rest are roosters. Chicks are 4 fewer than roosters. How many chicks do you have?
8
15 3 [OP_SUB] 4 [OP_SUB]
var_a = 15 var_b = 3 var_c = var_a - var_b var_d = 4 var_e = var_c - var_d print(int(var_e))
Arithmetic calculation
There are 950 stones. If there are 150 more white stones than black stones, how many black stones are there?
400
950 150 [OP_SUB] 2 [OP_DIV]
var_a = 950 var_b = 150 var_c = var_a - var_b var_d = 2 var_e = var_c / var_d print(int(var_e))
Possibility
Write the largest three-digit number that can be formed by using 2, 6, and 9 only once.
962
[OP_LIST_SOL] 2 6 9 [OP_LIST_EOL] 3 [OP_LIST_GET_PERM] 1 [OP_LIST_MAX]
var_a = 2 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 = 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 = 1 list_c=list_b.copy() list_c.sort() var_f = list_c[-var_e] print(int(var_f))
Arithmetic calculation
In the addition of two-digit numbers, the units digit of added number was originally 5 but was mistaken as 8. Also, when the number 7 in the tens place of the number being added was mistakenly calculated as 4, the calculated value was 111. Find the result of the correct calculation.
138
111 1 5 8 [OP_SUB] [OP_MUL] [OP_ADD] 10 7 4 [OP_SUB] [OP_MUL] [OP_ADD]
var_a = 111 var_b = 1 var_c = 5 var_d = 8 var_e = var_c - var_d var_f = var_b * var_e var_g = var_a + var_f var_h = 10 var_i = 7 var_j = 4 var_k = var_i - var_j var_l = var_h * var_k var_m = var_g + var_l print(int(var_m))
Possibility
Find the number in the hundredth place of the smallest number that can be made by using all of the given number cards 0, 5, and 8 once.
5
[OP_LIST_SOL] 0 5 8 [OP_LIST_EOL] [OP_LIST_LEN] [OP_LIST_GET_PERM] 1 [OP_LIST_MIN] 100 [OP_FDIV]
var_a = 0 var_b = 5 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-1] var_g = 100 var_h = var_f // var_g print(int(var_h))
Possibility
There is one ID photo each of Seokjin, Taehyung, Namjoon, Yoojeong, and Yuna. In how many ways can these pictures be arranged in a row?
120
[OP_LIST_SOL] Seokjin Taehyung Namjoon Yoojeong Yuna [OP_LIST_EOL] [OP_LIST_LEN] 5 [OP_PERM]
var_a = 'Seokjin' var_b = 'Taehyung' var_c = 'Namjoon' var_d = 'Yoojeong' var_e = 'Yuna' 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 = len(list_a) var_g = 5 var_h = 1 var_f = int(var_f) var_g = int(var_g) for i, elem in enumerate(range(var_g)): var_h = var_h * (var_f-i) print(int(var_h))
Correspondence
On a farm of 12 cows and 34 pigs, a few cows and three times as many pigs were sold on the market. When there are 30 remaining cows and pigs, how many cows sold?
4
12 34 [OP_ADD] 30 [OP_SUB] 1 3 [OP_ADD] [OP_DIV]
var_a = 12 var_b = 34 var_c = var_a + var_b var_d = 30 var_e = var_c - var_d var_f = 1 var_g = 3 var_h = var_f + var_g var_i = var_e / var_h print(int(var_i))
Geometry
How many candles are needed to place candles every 3 cm (cm) on the edge of a square table with a side of 90 centimeters (cm)?
120
90 4 [OP_MUL] 3 [OP_FDIV]
var_a = 90 var_b = 4 var_c = var_a * var_b var_d = 3 var_e = var_c // var_d print(int(var_e))
Correspondence
If there are four different natural numbers A, B, C, and D that satisfy A2B6-C97=543D, what are the possible values for A?
6
A2B6-C97=543D A [OP_DIGIT_UNK_SOLVER]
var_a = 'A2B6-C97=543D' 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))
Comparison
Junsu drank 0.331 liters (L) of milk, while Jimin drank 218 milliliters (㎖). Who drank more milk?
Junsu
[OP_LIST_SOL] Junsu Jimin [OP_LIST_EOL] [OP_LIST_SOL] 0.331 1000 [OP_MUL] 218 [OP_LIST_EOL] 1 [OP_LIST_MAX] [OP_LIST_INDEX] [OP_LIST_POP] [OP_LIST_GET]
var_a = 'Junsu' var_b = 'Jimin' 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 = 0.331 var_d = 1000 var_e = var_c * var_d var_f = 218 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) 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)
Possibility
You want to use 3 out of 0, 7, 4, and 5 allowing the repetition of digits to create a three-digit number. Find the difference between the second largest number and the third smallest number that can be made.
370
[OP_LIST_SOL] 0 7 4 5 [OP_LIST_EOL] 3 [OP_LIST_GET_PRODUCT] 2 [OP_LIST_MAX] 3 [OP_LIST_MIN] [OP_SUB] [OP_ABS]
var_a = 0 var_b = 7 var_c = 4 var_d = 5 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.product(list_b, repeat=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 = 2 list_c=list_b.copy() list_c.sort() var_g = list_c[-var_f] var_h = 3 list_d=list_b.copy() list_d.sort() var_i = list_d[var_h-1] var_j = var_g - var_i var_k = abs(var_j) print(int(var_k))
Comparison
There are several chairs inside the church. If 9 students sit per chair, one student cannot sit, and if 10 students sit per chair, 1 chair becomes vacant. How many students went to church?
100
1 10 [OP_ADD] 10 9 [OP_SUB] [OP_DIV] 9 [OP_MUL] 1 [OP_ADD]
var_a = 1 var_b = 10 var_c = var_a + var_b var_d = 10 var_e = 9 var_f = var_d - var_e var_g = var_c / var_f var_h = 9 var_i = var_g * var_h var_j = 1 var_k = var_i + var_j print(int(var_k))
Arithmetic calculation
There are four numbers 10, 11, 12, and 13. What is the value of difference between the 3rd smallest number and the 2nd smallest number?
1
[OP_LIST_SOL] 10 11 12 13 [OP_LIST_EOL] 3 [OP_LIST_MIN] 2 [OP_LIST_MIN] [OP_SUB]
var_a = 10 var_b = 11 var_c = 12 var_d = 13 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=list_a.copy() list_b.sort() var_f = list_b[var_e-1] var_g = 2 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))
Correspondence
I was supposed to subtract 36 from a particular number, but mistakenly subtracted 63, and as a result, got 8 as an answer. What should be the answer to the correct calculation?
35
8 63 [OP_ADD] 36 [OP_SUB]
var_a = 8 var_b = 63 var_c = var_a + var_b var_d = 36 var_e = var_c - var_d print(int(var_e))
Possibility
Each box contains 3 red balls and 5 blue balls. When Jungkook has 2 boxes, how many red balls does Jungkook have?
6
3 2 [OP_MUL]
var_a = 3 var_b = 2 var_c = var_a * var_b print(int(var_c))
Geometry
After arranging the vases in a square shape, there were 6 bottles left. So, I tried to increase the width and length by one row each, but 11 vases were insufficient. If you arrange these vases in 7 rows, how many bottles are there in 1 row?
10
6 11 [OP_ADD] 1 [OP_SUB] 2 [OP_DIV] 2 [OP_POW] 6 [OP_ADD] 7 [OP_DIV]
var_a = 6 var_b = 11 var_c = var_a + var_b var_d = 1 var_e = var_c - var_d var_f = 2 var_g = var_e / var_f var_h = 2 var_i = var_g ** var_h var_j = 6 var_k = var_i + var_j var_l = 7 var_m = var_k / var_l print(int(var_m))
Geometry
What is the sum of the lengths in centimeters (cm) of all the edges of a cube with one edge length of 15 centimeters (cm)?
180
15 4 3 [OP_MUL] [OP_MUL]
var_a = 15 var_b = 4 var_c = 3 var_d = var_b * var_c var_e = var_a * var_d print(int(var_e))
Possibility
Three cards of numbers from 1 to 9 are used to create a certain three-digit number. If the hundredth place is 7 and the tens place is 4, how many digits can be placed in the ones place?
7
1 9 1 [OP_LIST_ARANGE] [OP_LIST_SOL] 7 4 [OP_LIST_EOL] [OP_SET_DIFFERENCE] [OP_LIST_LEN]
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 = 7 var_e = 4 list_b= [] 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() list_c = list(set(list_a) - set(list_b)) var_f = len(list_c) print(int(var_f))
Correspondence
Hyungjun used half of his ribbon and 2000 centimeters (cm) of ribbon to wrap the first box, and used half of the remaining ribbon and 2000 centimeters (cm) of ribbon to wrap the second box, but there was no ribbon left. How many centimeters (cm) is the ribbon Hyeongjun had at first?
12000
0 2000 [OP_ADD] 2 [OP_MUL] 2000 [OP_ADD] 2 [OP_MUL]
var_a = 0 var_b = 2000 var_c = var_a + var_b var_d = 2 var_e = var_c * var_d var_f = 2000 var_g = var_e + var_f var_h = 2 var_i = var_g * var_h print(int(var_i))
Geometry
There is a box with an inside volume of 138000000 cubic centimeters (cm3), six sides each being a rectangle, equal opposite sides, twelve edges, and eight vertices. If the area of the top surface is 115 square meters (m2), find the height in meters (m).
12
1380000000 100 3 [OP_POW] [OP_DIV] 115 [OP_DIV]
var_a = 1380000000 var_b = 100 var_c = 3 var_d = var_b ** var_c var_e = var_a / var_d var_f = 115 var_g = var_e / var_f print(int(var_g))
Arithmetic calculation
If the sum of the two pages of the book Eunji has opened is 137, what is the larger number of the two pages Eunji has opened?
69
137 2 [OP_FDIV] 1 [OP_ADD]
var_a = 137 var_b = 2 var_c = var_a // var_b var_d = 1 var_e = var_c + var_d print(int(var_e))
Geometry
Find the number of all faces of a regular icosahedron.
20
20
var_a = 20 print(int(var_a))
Geometry
A park is in the shape of a square with sides measuring 10 meters (m). We want to divide the park into right triangles with a base of 1 meters (m) and a height of 3 meters (m). What is the maximum number of zones that can be divided?
66
10 2 [OP_POW] 1 3 [OP_MUL] [OP_FDIV] 2 [OP_MUL]
var_a = 10 var_b = 2 var_c = var_a ** var_b var_d = 1 var_e = 3 var_f = var_d * var_e var_g = var_c // var_f var_h = 2 var_i = var_g * var_h print(int(var_i))
Arithmetic calculation
You want to hand out 269 pens each of which costs 150 won to 29 students equally. If you have to buy the lacking pens, find how much money you need.
3150
29 269 29 [OP_MOD] [OP_SUB] 150 [OP_MUL]
var_a = 29 var_b = 269 var_c = 29 var_d = var_b % var_c var_e = var_a - var_d var_f = 150 var_g = var_e * var_f print(int(var_g))
Correspondence
A prime number was supposed to be divided by 8, but multiplied by 8 by mistake, and it became 69.76. Find the correct value.
1.09
69.76 8 [OP_DIV] 8 [OP_DIV]
var_a = 69.76 var_b = 8 var_c = var_a / var_b var_d = 8 var_e = var_c / var_d print('{:.2f}'.format(round(var_e+1e-10,2)))
Comparison
Which is the smallest among circle A with a diameter of 10 centimeters (cm), circle B with a radius of 4 centimeters (cm), and circle C with a sum of 9 in its diameter and radius?
C
[OP_LIST_SOL] A B C [OP_LIST_EOL] [OP_LIST_SOL] 10 2 [OP_DIV] 4 9 2 1 [OP_ADD] [OP_DIV] [OP_LIST_EOL] 1 [OP_LIST_MIN] [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 = 10 var_e = 2 var_f = var_d / var_e var_g = 4 var_h = 9 var_i = 2 var_j = 1 var_k = var_i + var_j var_l = var_h / 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_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-1] var_o = list_b.index(var_n)+1 var_p = list_a[var_o-1] print(var_p)
Arithmetic calculation
There are 34 hibiscus. There are 13 fewer hibiscus than chrysanthemums. There are 23 more chrysanthemums than dandelions. How many hibiscus, chrysanthemum, and dandelion are there in total?
105
34 34 13 [OP_ADD] [OP_ADD] 34 13 [OP_ADD] 23 [OP_SUB] [OP_ADD]
var_a = 34 var_b = 34 var_c = 13 var_d = var_b + var_c var_e = var_a + var_d var_f = 34 var_g = 13 var_h = var_f + var_g var_i = 23 var_j = var_h - var_i var_k = var_e + var_j print(int(var_k))
Correspondence
There are two different numbers A and B. Find B from the two-digit addition formula AB+25=B3.
8
AB+25=B3 B [OP_DIGIT_UNK_SOLVER]
var_a = 'AB+25=B3' 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
A regular octagonal fence was built using eight 2.3-meter (m) wooden poles. What is the perimeter of this fence in centimeters (cm)?
1840
2.3 8 [OP_MUL] 100 [OP_MUL]
var_a = 2.3 var_b = 8 var_c = var_a * var_b var_d = 100 var_e = var_c * var_d print(int(eval('{:.2f}'.format(round(var_e+1e-10,2)))))
Arithmetic calculation
If a ball that bounces 1/4 of its height is dropped from a height of 12.8 meters (m), how many centimeters (cm) will the third bounce be?
20
12.8 1/4 3 [OP_POW] [OP_MUL] 100 [OP_MUL]
var_a = 12.8 var_b = 0.25 var_c = 3 var_d = var_b ** var_c var_e = var_a * var_d var_f = 100 var_g = var_e * var_f print(int(var_g))
Geometry
The circumference of a wheel is 94.2 centimeters (cm). If the diameter of this wheel is 30 centimeters (cm), how many times the circumference of the wheel is than the diameter?
3.14
94.2 30 [OP_DIV]
var_a = 94.2 var_b = 30 var_c = var_a / var_b print('{:.2f}'.format(round(var_c+1e-10,2)))
Arithmetic calculation
How many kilograms (kg) does 1 meter (m) of marble weigh if 3/4 meter (m) of marble weighs 15/2 kilograms (kg)?
10
15/2 3/4 [OP_DIV]
var_a = 7.5 var_b = 0.75 var_c = var_a / var_b print(int(var_c))
Arithmetic calculation
Seokgi and Yeseul are going to share a wire that is 1 meter (m) and 50 centimeters (cm) long. Find how many centimeters (cm) of wire must Seokgi take for him to get 16 centimeters (cm) shorter wire than Yeseul's.
67
1 100 [OP_MUL] 50 [OP_ADD] 16 [OP_SUB] 2 [OP_DIV]
var_a = 1 var_b = 100 var_c = var_a * var_b var_d = 50 var_e = var_c + var_d var_f = 16 var_g = var_e - var_f var_h = 2 var_i = var_g / var_h print(int(var_i))
Arithmetic calculation
The price of one onion is 200 won. How much does one bag of onions cost, if you divide 180 onions into 6 bags?
6000
180 6 [OP_DIV] 200 [OP_MUL]
var_a = 180 var_b = 6 var_c = var_a / var_b var_d = 200 var_e = var_c * var_d print(int(var_e))
Possibility
Find the sum of the largest and smallest six-digit numbers that can be formed by using 2, 0, 4, 1, 5, and 8 only once.
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))
Geometry
A rectangular wrapping paper is 6 centimeters (cm) wide and 28 centimeters (cm) in perimeter. Find the area of the area that can be covered with this wrapping paper.
48
28 2 [OP_DIV] 6 [OP_SUB] 6 [OP_MUL]
var_a = 28 var_b = 2 var_c = var_a / var_b var_d = 6 var_e = var_c - var_d var_f = 6 var_g = var_e * var_f print(int(var_g))
Arithmetic calculation
Hyeongi studies for 0.6 hours a day. For how many hours did Hyeongi study in 3 weeks?
12.6
0.6 7 [OP_MUL] 3 [OP_MUL]
var_a = 0.6 var_b = 7 var_c = var_a * var_b var_d = 3 var_e = var_c * var_d print('{:.2f}'.format(round(var_e+1e-10,2)))
Geometry
I cut 78 centimeters (cm) of wire and used all of them to make one triangle and one square. If the sum of the lengths of the three sides of the triangle is 46 centimeters (cm), how many centimeters (cm) is the side of the square?
8
78 46 [OP_SUB] 4 [OP_DIV]
var_a = 78 var_b = 46 var_c = var_a - var_b var_d = 4 var_e = var_c / var_d print(int(var_e))
Arithmetic calculation
Six friends are going to rent bikes for a ride in the park. A 30-minute rental of a bicycle is 4,000 won. How much does one person have to pay to rent 4 bicycles for 3 hours?
16000
3 60 [OP_MUL] 30 [OP_DIV] 4000 [OP_MUL] 4 [OP_MUL] 6 [OP_DIV]
var_a = 3 var_b = 60 var_c = var_a * var_b var_d = 30 var_e = var_c / var_d var_f = 4000 var_g = var_e * var_f var_h = 4 var_i = var_g * var_h var_j = 6 var_k = var_i / var_j print(int(var_k))
Arithmetic calculation
It requires 30 pictures to play 1 second of the animated film called 'The Snow Prince'. How many pictures are necessary to make a 25-second screening?
750
30 25 [OP_MUL]
var_a = 30 var_b = 25 var_c = var_a * var_b print(int(var_c))
Geometry
You want to create a rectangular field that has the same area as a triangular field with a base of 7.2 meters (m) and a height of 7 meters (m). If the width of a rectangular field is 4 meters (m), how many meters (m) should the length be?
6.3
7.2 7 [OP_MUL] 2 [OP_DIV] 4 [OP_DIV]
var_a = 7.2 var_b = 7 var_c = var_a * var_b var_d = 2 var_e = var_c / var_d var_f = 4 var_g = var_e / var_f print('{:.2f}'.format(round(var_g+1e-10,2)))
Arithmetic calculation
At first, Jungkook had 8 apples. How many apples does Jungkook have in total when he is given 7 apples?
15
8 7 [OP_ADD]
var_a = 8 var_b = 7 var_c = var_a + var_b print(int(var_c))
Arithmetic calculation
Jungkook tries to divide 10 balls into boxes containing 5 balls each. How many boxes does Jungkook need?
2
10 5 [OP_DIV]
var_a = 10 var_b = 5 var_c = var_a / var_b print(int(var_c))
Geometry
Haechan used all the ribbon tapes he had to make a rectangle of 7 centimeters (cm) long and 5 centimeters (cm) wide. If he used this ribbon tape again to make a square, how many centimeters (cm) would each side be?
6
7 5 [OP_ADD] 2 [OP_MUL] 4 [OP_DIV]
var_a = 7 var_b = 5 var_c = var_a + var_b var_d = 2 var_e = var_c * var_d var_f = 4 var_g = var_e / var_f print(int(var_g))
Correspondence
If you divide a number by 1.2, subtract 22.5, multiply that number by 0.6, then add 10.5, you can get 30. Find out this number.
66
30 10.5 [OP_SUB] 0.6 [OP_DIV] 22.5 [OP_ADD] 1.2 [OP_MUL]
var_a = 30 var_b = 10.5 var_c = var_a - var_b var_d = 0.6 var_e = var_c / var_d var_f = 22.5 var_g = var_e + var_f var_h = 1.2 var_i = var_g * var_h print(int(var_i))