philschmid/DMath huggingface dataset:
Category: Comparison

Question (EN): Cheolmin read 518 pages of a children's book in 2 weeks, and Seongmin read 328 pages in 8 days. Who read more in one day?
Question (KO): 철민이는 동화책을 2주일 동안 518쪽 읽었고, 성민이는 8일 동안 328쪽 읽었다. 하루 동안 누가 더 많이 읽은 셈인가?

Answer: Seongmin

Solution (Python):
var_a = 'Cheolmin'
var_b = 'Seongmin'
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 = 518
var_d = 2
var_e = 7
var_f = var_d * var_e
var_g = var_c / var_f
var_h = 328
var_i = 8
var_j = var_h / var_i
list_b= []
if "/" in str(var_j):
    var_j = eval(str(var_j))
list_b.append(var_j)
if "/" in str(var_g):
    var_g = eval(str(var_g))
list_b.append(var_g)
list_b.reverse()
var_k = 1
list_c=list_b.copy()
list_c.sort()
var_l = list_c[-var_k]
var_m = list_b.index(var_l)+1
var_n = list_a[var_m-1]
print(var_n)
Category: Comparison

Question (EN): Yoongi collects 4, Jungkook collects a number adding 3 to 6, and Yuna collects 5. Who has the smallest number?
Question (KO): 윤기는 4, 정국이는 6에서 3을 합한 수를 모았고, 유나는 5를 모았습니다. 누가 가장 작은 수를 가지고 있나요?

Answer: Yoongi

Solution (Python):
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-1]
var_k = list_b.index(var_j)+1
var_l = list_a[var_k-1]
print(var_l)
Category: Correspondence

Question (EN): I made a mistake in dividing a number by 20, so I divided a number by 22 and got 2. How much is it if I calculate it correctly?
Question (KO): 어떤 수에 20을 나누어야 할 것을 22를 나누어 2가 나왔습니다. 바르게 계산하면 얼마인가요?

Answer: 2.2

Solution (Python):
var_a = 2
var_b = 22
var_c = var_a * var_b
var_d = 20
var_e = var_c / var_d
print('{:.2f}'.format(round(var_e+1e-10,2)))
Category: Arithmetic calculation

Question (EN): How many trees will be needed if trees are planted on both ends of the road, evenly spaced at 32.5 m (m) intervals on a road that is 650 meters (m) long? However, the thickness of the wood is not considered.
Question (KO): 길이가 650미터(m)인 도로에 32.5미터(m) 간격으로 일정하게 나무를 심으려고 할 때, 도로의 양 끝에 나무를 심는다면 모두 몇 그루의 나무가 필요합니까? 단, 나무의 두께는 생각하지 않습니다.

Answer: 21

Solution (Python):
var_a = 650
var_b = 32.5
var_c = var_a // var_b
var_d = 1
var_e = var_c + var_d
print(int(var_e))
Category: Correspondence

Question (EN): There are four different numbers A, B, C, and D. Find C from the four-digit addition formula 4A5B+C2D7=7070.
Question (KO): 서로 다른 네 수 A, B, C, D가 있습니다. 네 자리 수끼리의 덧셈식 4A5B+C2D7=7070에서 C를 구하시오.

Answer: 2

Solution (Python):
var_a = '4A5B+C2D7=7070'
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] = 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))
Category: Geometry

Question (EN): There is a wall in the shape of a rectangle with a width of 36 centimeters (cm) and a height of 72 centimeters (cm). On this wall, you want to attach tiles that are 3 centimeters (cm) and 4 centimeters (cm) in length and width, respectively, without any empty space. If it costs 2500 won per tile, how much does it cost?
Question (KO): 어떤 벽이 가로와 세로의 길이가 각각 36센티미터(㎝), 72센티미터(㎝)인 직사각형 모양이다. 이 벽에 가로와 세로의 길이가 각각 3센티미터(㎝), 4센티미터(㎝)인 타일을 빈 공간 없이 붙이려고 합니다. 타일 하나에 2500원 일 때, 얼마가 드는지 구하시오.

Answer: 540000

Solution (Python):
var_a = 36
var_b = 3
var_c = var_a // var_b
var_d = 72
var_e = 4
var_f = var_d // var_e
var_g = var_c * var_f
var_h = 2500
var_i = var_g * var_h
print(int(var_i))
Category: Geometry

Question (EN): Using yarn, I made a regular pentagon with a side of 16 centimeters (cm). I used all of these yarns to make a regular octagon. Find the length of one side of this regular octagon.
Question (KO): 실을 사용하여 한 변의 길이가 16센티미터(㎝)인 정오각형을 만들었습니다. 이 실을 똑같이 사용해 모두 사용하여 정팔각형을 만들었습니다. 이 정팔각형의 한 변의 길이를 구하시오.

Answer: 10

Solution (Python):
var_a = 16
var_b = 5
var_c = var_a * var_b
var_d = 8
var_e = var_c / var_d
print(int(var_e))
Category: Geometry

Question (EN): Find the height in centimeters (cm) of a cuboid whose base area is 50 square centimeters (cm2) and its volume is 2000 cubic centimeters (cm3).
Question (KO): 밑면의 넓이가 50제곱센티미터(㎠)이고, 부피가 2000세제곱센티미터(㎤)인 직육면체의 높이는 몇 센티미터(㎝)인지 구하시오.

Answer: 40

Solution (Python):
var_a = 2000
var_b = 50
var_c = var_a / var_b
print(int(var_c))
Category: Geometry

Question (EN): Minjeong is taking a walk in a square-shaped park. Given that one side of this park is 40 meters (m) long, how many meters (m) did Minjeong walk?
Question (KO): 민정이는 정사각형 모양의 공원을 산책하고 있습니다. 이 공원의 한 변의 길이가 40미터(m)일 때, 민정이가 걸은 거리는 몇 미터(m)일까요?

Answer: 160

Solution (Python):
var_a = 40
var_b = 4
var_c = var_a * var_b
print(int(var_c))
Category: Geometry

Question (EN): Find how much it will be if you divide the area of a circle with a radius of 8 centimeters (cm) by the area of a circle with a diameter of 8 centimeters (cm). Note that the pi is assumed to be 3.14.
Question (KO): 반지름이 8센티미터(㎝)인 원의 넓이를 지름이 8센티미터(㎝)인 원의 넓이로 나누면 몇인지 구하시오. 단, 원주율은 3.14로 가정한다.

Answer: 4

Solution (Python):
var_a = 3.14
var_b = 8
var_c = var_a * var_b
var_d = 8
var_e = var_c * var_d
var_f = 3.14
var_g = 8
var_h = 2
var_i = var_g / var_h
var_j = var_f * var_i
var_k = 8
var_l = 2
var_m = var_k / var_l
var_n = var_j * var_m
var_o = var_e / var_n
print(int(var_o))
Category: Comparison

Question (EN): You are going to load three cargoes, A, B, and C, into the cargo hold. Cargo A is larger than cargo B, and cargo C is larger than cargo A. If you want to load the smallest cargo first, which cargo should be loaded first?
Question (KO): 화물칸에 A, B, C 3개의 화물을 실으려고 합니다. A 화물은 B 화물보다 크고 C 화물은 A 화물보다 큽니다. 가장 작은 화물을 먼저 실으려고 한다면 가장 먼저 실어야 하는 화물은 무엇일까요?

Answer: B

Solution (Python):
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 = 'A'
var_e = 'B'
var_f = '>'
var_g = 'C'
var_h = 'A'
var_i = '>'
list_b= []
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)
if "/" in str(var_d):
    var_d = eval(str(var_d))
list_b.append(var_d)
list_b.reverse()
global item_name_index_dict
items_name_list = list_a.copy()
conditions = []
condition_list = list_b.copy()
temp_stack = []
for index_, cond_ in enumerate(map(str, condition_list)):
    if cond_ in ("<", ">", "="):
        operand_right = temp_stack.pop()
        operand_left = temp_stack.pop()
        if cond_ == "=":
            cond_ = "=="
        conditions.append(f"{operand_left} {cond_} {operand_right}")
    else:
        if not cond_.isdigit():
            cond_ = "{" + cond_ + "}"
        temp_stack.append(cond_)
item_name_index_dict = {}
for perm in itertools.permutations(range(1, len(items_name_list) + 1)):
    item_name_index_dict = dict(zip(items_name_list, perm))
    formatted_conditions = \
        [condition.format_map(item_name_index_dict) for condition in conditions]
    if all(map(eval, formatted_conditions)):
        break
list_c = list(item_name_index_dict.keys())
list_c.sort(key=item_name_index_dict.get, reverse=True)
var_j = len(list_c)
var_k = list_c[var_j-1]
print(var_k)
Category: Arithmetic calculation

Question (EN): Yuna gave 12 of the marbles she had to her younger sister and received 5 from her older sister. Then she gave half of the marbles she had to Namjoon and received 3 from Yoongi, making 17. How many marbles did Yuna have in the beginning?
Question (KO): 유나는 가지고 있던 구슬 중에서 12개를 동생에게 주고 언니에게 5개를 받았습니다. 그다음 가지고 있던 구슬의 절반을 남준이에게 주고 윤기에게 3개를 받아서 17개가 되었습니다. 처음에 유나가 가지고 있던 구슬은 몇 개입니까?

Answer: 35

Solution (Python):
var_a = 17
var_b = 3
var_c = var_a - var_b
var_d = 2
var_e = var_c * var_d
var_f = 5
var_g = var_e - var_f
var_h = 12
var_i = var_g + var_h
print(int(var_i))
Category: Correspondence

Question (EN): Multiplying 0.55 by a number gives 4.235. What is the value of the number divided by 0.55?
Question (KO): 0.55에 어떤 수를 곱하였더니 4.235가 되었습니다. 어떤 수를 0.55로 나누면 얼마입니까?

Answer: 14

Solution (Python):
var_a = 4.235
var_b = 0.55
var_c = var_a / var_b
var_d = 0.55
var_e = var_c / var_d
print(int(var_e))
Category: Arithmetic calculation

Question (EN): There are 25 girls in class (A), and there are 3 more girls than boys. How many students are in class (A)?
Question (KO): (가) 반에는 여학생이 25명 있고, 여학생이 남학생보다 3명 더 많습니다. (가) 반 학생 수는 모두 몇 명입니까?

Answer: 47

Solution (Python):
var_a = 25
var_b = 25
var_c = 3
var_d = var_b - var_c
var_e = var_a + var_d
print(int(var_e))
Category: Correspondence

Question (EN): Jung Hyun used 10 more than 1/4 of the 100 won coins she had at the mart, 5 less than 3/5 of the remaining coins to ride the bus, and gave 12 of the remaining coins to her younger brother. Find the number of 100 won coins that Jung Hyun had at the beginning when the number of coins she had at the end was 13.
Question (KO): 정현이는 마트에서 가지고 있던 100원 동전의 1/4보다 10개 많게 사용했고, 나머지 동전의 3/5보다 5개 적게 버스 타는데 사용하였고, 그 나머지 동전 중 12개를 동생에게 주었다. 정현이가 마지막에 가진 동전의 개수가 13개일 때 정현이가 처음에 가지고 있던 100원 동전의 개수를 구하시오.

Answer: 80

Solution (Python):
var_a = 13
var_b = 12
var_c = var_a + var_b
var_d = 5
var_e = var_c - var_d
var_f = 1
var_g = 0.6
var_h = var_f - var_g
var_i = var_e / var_h
var_j = 10
var_k = var_i + var_j
var_l = 1
var_m = 0.25
var_n = var_l - var_m
var_o = var_k / var_n
print(int(var_o))
Category: Arithmetic calculation

Question (EN): The ducks laid 1925 eggs yesterday and 138 fewer eggs today than yesterday. Find out the sum of the eggs laid yesterday and today.
Question (KO): 오리들이 어제는 알을 1925개 낳았고, 오늘은 어제보다 알을 138개 적게 낳았습니다. 어제와 오늘 낳은 알은 모두 몇 개입니까?

Answer: 3712

Solution (Python):
var_a = 1925
var_b = 1925
var_c = 138
var_d = var_b - var_c
var_e = var_a + var_d
print(int(var_e))
Category: Geometry

Question (EN): Any number is divisible by 3 and even divisible by 4. Find the smallest value of any possible number.
Question (KO): 어떠한 수는 3으로도 나누어떨어지고 4로도 나누어떨어진다. 가능한 어떤 수 중 가장 작은 값을 구하시오.

Answer: 12

Solution (Python):
var_a = 3
var_b = 4
var_c = var_b * var_a / math.gcd(int(var_b), int(var_a))
print(int(var_c))
Category: Geometry

Question (EN): What is the length of the hypotenuse of a right triangle if the length of the non-hypotenuse is 5 and the other non-hypotenuse is 12?
Question (KO): 직각삼각형의 빗변이 아닌 한 변의 길이가 5, 나머지 빗변이 아닌 한 변의 길이가 12일 때 빗변의 길이는 얼마입니까?

Answer: 13

Solution (Python):
var_a = 12
var_b = 2
var_c = var_a ** var_b
var_d = 5
var_e = 2
var_f = var_d ** var_e
var_g = var_c + var_f
var_h = 0.5
var_i = var_g ** var_h
print(int(var_i))
Category: Possibility

Question (EN): How many 3-digit numbers can be made by using all three 0, 2, and 9 number cards once?
Question (KO): 다음과 같이 0, 2, 9 숫자카드 3장을 한 번씩 모두 사용하여 만들 수 있는 3자리 수를 모두 구한다면 전부 몇 개입니까?

Answer: 4

Solution (Python):
var_a = 0
var_b = 2
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 = len(list_b)
print(int(var_e))
Category: Geometry

Question (EN): I used all of the ribbon with a length of 78 centimeters (cm) to make one triangle and one square. If the perimeter of the triangle is 46 centimeters (cm), how many centimeters (cm) is the length of one side of the square?
Question (KO): 길이가 78센티미터(㎝)인 리본을 모두 사용하여 삼각형 1개와 정사각형 1개를 만들었습니다. 삼각형의 둘레가 46센티미터(㎝)라면, 정사각형의 한 변의 길이는 몇 센티미터(㎝)일지 구하시오.

Answer: 8

Solution (Python):
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))
Category: Arithmetic calculation

Question (EN): When Minjun was late, he went to school at 15 kilometers (km) per hour, and when he came back at a leisurely pace of 10 kilometers (km) per hour, it took 30 minutes longer than when he went to school. How long did it take to go to school?
Question (KO): 민준이는 지각을 하여 학교로 갈 때 시속 15킬로미터(㎞)의 속도로 갔고, 돌아올 때는 여유롭게 시속 10킬로미터(㎞)속도로 왔더니 등교 때 보다 30분이 더 걸렸다. 갈 때는 얼마나 시간이 걸렸는가?

Answer: 1

Solution (Python):
var_a = 10
var_b = 30
var_c = 60
var_d = var_b / var_c
var_e = var_a * var_d
var_f = 15
var_g = 10
var_h = var_f - var_g
var_i = var_e / var_h
print(int(var_i))
Category: Arithmetic calculation

Question (EN): What is the sum of all even numbers from 1 to 10?
Question (KO): 1부터 10까지의 짝수를 모두 더한 값은 얼마인지 구하시오.

Answer: 30

Solution (Python):
var_a = 1
var_b = 10
list_a = []
if var_a%2!=0:
    for i in range(var_a+1, var_b+1, 2):
        list_a.append(i)
else:
    for i in range(var_a, var_b+1, 2):
        list_a.append(i)
list_a = [float(i) for i in list_a]
var_c = sum(list_a)
print(int(var_c))
Category: Correspondence

Question (EN): Find the number. The number results in 24 when you add 12 and subtract 27.
Question (KO): 어떤 수를 구하시오. 어떤 수는 12를 더하고 27을 빼면 24가 되는 수입니다.

Answer: 39

Solution (Python):
var_a = 24
var_b = 27
var_c = var_a + var_b
var_d = 12
var_e = var_c - var_d
print(int(var_e))
Category: Arithmetic calculation

Question (EN): Find the number of numbers that are divisors of 32 or factors of 24.
Question (KO): 32의 약수이거나 24의 약수인 수를 모두 구하시오.

Answer: 10

Solution (Python):
var_a = 32
list_a = []
num_sqrt = int(math.sqrt(var_a))
for i in range(1, num_sqrt+1):
    if var_a % i == 0:
        list_a.append(i)
        list_a.append(int(var_a/i))
list_a = sorted(set(list_a))
var_b = 24
list_b = []
num_sqrt = int(math.sqrt(var_b))
for i in range(1, num_sqrt+1):
    if var_b % i == 0:
        list_b.append(i)
        list_b.append(int(var_b/i))
list_b = sorted(set(list_b))
list_c = list(set(list_a) | set(list_b))
var_c = len(list_c)
print(int(var_c))
Category: Arithmetic calculation

Question (EN): Hyungjun drinks 200 milliliters (ml) of Coke every day, which contains 2 liters (L). How many days will it take him to finish drinking Coke if he has been drinking Coke for 3 days?
Question (KO): 형준이는 2리터(L)가 들어있는 콜라를 매일 200밀리리터(㎖)씩 나눠 마십니다. 지금까지 3일 동안 콜라를 마셨을 때 콜라를 다 마시는 데엔 며칠이 걸립니까?

Answer: 7

Solution (Python):
var_a = 2
var_b = 1000
var_c = var_a * var_b
var_d = 200
var_e = 3
var_f = var_d * var_e
var_g = var_c - var_f
var_h = 200
var_i = var_g / var_h
var_j = 1
var_k=int(((var_i+9*10**(var_j-2))//(10**(var_j-1)))*10**(var_j-1))

print(int(var_k))
Category: Comparison

Question (EN): If you put 5 notebooks of the same weight on a bookshelf, the total weight is 2.9 kilograms (kg). If three books of the same weight are placed on a bookshelf, the total weight is 2.51 kilograms (kg). If the weight of the bookshelf is 0.2 kilograms (kg), find out which one is heavier, one book or one notebook.
Question (KO): 무게가 같은 연습장 5 개를 책꽂이에 꽂으면 총 무게는 2.9킬로그램(㎏)입니다. 무게가 같은 책 3 개를 책꽂이에 꽂으면 총 무게는 2.51킬로그램(㎏) 입니다. 책꽂이의 무게가 0.2킬로그램(㎏)일 때, 책 한 권과 연습장 한 권 중 어느 것이 더 무거운지 구하시오.

Answer: book

Solution (Python):
var_a = 'notebook'
var_b = 'book'
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.9
var_d = 0.2
var_e = var_c - var_d
var_f = 5
var_g = var_e / var_f
var_h = 2.51
var_i = 0.2
var_j = var_h - var_i
var_k = 3
var_l = var_j / var_k
list_b= []
if "/" in str(var_l):
    var_l = eval(str(var_l))
list_b.append(var_l)
if "/" in str(var_g):
    var_g = eval(str(var_g))
list_b.append(var_g)
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)
Category: Geometry

Question (EN): We made a square with a side length of 6 centimeters (cm) by wire. If you increase the length of each side by 1 centimeters (cm), how much is the difference of the area from the original square?
Question (KO): 한 변의 길이가 6센티미터(㎝)인 정사각형을 철사로 만들었습니다. 각 네 변의 길이를 1센티미터(㎝)씩 늘렸을 때 원래 정사각형의 넓이와의 차이는 얼마입니까?

Answer: 13

Solution (Python):
var_a = 6
var_b = 1
var_c = var_a + var_b
var_d = 2
var_e = var_c ** var_d
var_f = 6
var_g = 2
var_h = var_f ** var_g
var_i = var_e - var_h
print(int(var_i))
Category: Correspondence

Question (EN): When 7 strings of the same length were thread together, the total length of it was 98 centimeters (cm). Find the length of one string.
Question (KO): 동일한 길이의 끈 7개를 이었더니 그 길이가 98센티미터(㎝)였다. 끈 하나의 길이가 얼마인지 구하시오.

Answer: 14

Solution (Python):
var_a = 98
var_b = 7
var_c = var_a / var_b
print(int(var_c))
Category: Geometry

Question (EN): How many bases are there in a pyramid?
Question (KO): 각뿔의 밑면의 수를 구하시오.

Answer: 1

Solution (Python):
var_a = 1
print(int(var_a))
Category: Comparison

Question (EN): Yoongi has the number 4, and Jungkook has the number that is 6 multiplied by 3. Which of the two has the larger number?
Question (KO): 윤기는 4, 정국이는 6에서 3을 곱한 수를 모았습니다. 둘 중 큰 숫자를 가진 사람은 누구입니까?

Answer: Jungkook

Solution (Python):
var_a = 'Yoongi'
var_b = 'Jungkook'
list_a= []
if "/" in str(var_b):
    var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
    var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_c = 4
var_d = 6
var_e = 3
var_f = var_d * var_e
list_b= []
if "/" in str(var_f):
    var_f = eval(str(var_f))
list_b.append(var_f)
if "/" in str(var_c):
    var_c = eval(str(var_c))
list_b.append(var_c)
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)
Category: Possibility

Question (EN): I gave 7 indistinguishable locks to Jungkook and Hoseok. Jungkook and Hoseok each received at least one lock. Find the number of ways to divide locks.
Question (KO): 정국이와 호석이에게 구분할 수 없는 자물쇠 7개를 나누어 주었습니다. 정국이와 호석이는 각자 적어도 1개의 자물쇠를 받았습니다. 자물쇠를 나누어주는 방법의 개수를 구하시오.

Answer: 6

Solution (Python):
var_a = 7
var_b = 2
var_c = 1
var_d = var_b * var_c
var_e = var_a - var_d
var_f = 1
var_g = var_e + var_f
print(int(var_g))
Category: Comparison

Question (EN): A horse, a cow, a pig, a sheep, a rabbit, and a squirrel sequentially entered the fence in that sequence. Which animal took the 4th place?
Question (KO): 말, 소, 돼지, 양, 토끼, 다람쥐 순으로 울타리 안으로 들어왔다. 4위를 차지한 동물은?

Answer: sheep

Solution (Python):
var_a = 'horse'
var_b = 'cow'
var_c = 'pig'
var_d = 'sheep'
var_e = 'rabbit'
var_f = 'squirrel'
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 = 4
var_h = list_a[var_g-1]
print(var_h)
Category: Geometry

Question (EN): The sum of the lengths of the four sides of a rectangle with sides measuring 7centimeters (cm) and 5centimeters (cm) is equal to the sum of the lengths of the four sides of a square. Find the length of one side of the square.
Question (KO): 한 변이 7센티미터(㎝)이고 나머지 한 변이 5센티미터(㎝)인 직사각형의 네 변의 길이의 합과 정사각형의 네 변의 길이의 합이 같다고 합니다. 정사각형의 한 변의 길이를 구하시오.

Answer: 6

Solution (Python):
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))
Category: Correspondence

Question (EN): Multiply 0.55 by a number and add 4 to get 8.235. What do you get when the number is divided by 0.55?
Question (KO): 0.55에 어떤 수를 곱하고 4를 더하였더니 8.235가 되었습니다. 어떤 수를 0.55로 나누면 얼마입니까?

Answer: 14

Solution (Python):
var_a = 8.235
var_b = 4
var_c = var_a - var_b
var_d = 0.55
var_e = var_c / var_d
var_f = 0.55
var_g = var_e / var_f
print(int(eval('{:.2f}'.format(round(var_g+1e-10,2)))))
Category: Arithmetic calculation

Question (EN): There are numbers whose quotient is 11 when divided by 75. What is the largest out of these numbers?
Question (KO): 75로 나누었더니 몫이 11이 되는 어떤 수가 있습니다. 어떤 수 중 가장 큰 수는 무엇입니까?

Answer: 899

Solution (Python):
var_a = 11
var_b = 75
var_c = var_a * var_b
var_d = 75
var_e = 1
var_f = var_d - var_e
var_g = var_c + var_f
print(int(var_g))
Category: Possibility

Question (EN): Find the total number of games played when 5 classes play dodgeball once against each other.
Question (KO): 5개 반이 서로 한 번씩 피구 경기를 할 때, 이루어지는 경기의 총 수를 구하시오.

Answer: 10

Solution (Python):
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))
Category: Arithmetic calculation

Question (EN): Bus passengers can ride up to 30 at a time. At least how many trips does the bus have to make to pick up all 1284 passengers once?
Question (KO): 버스 승객은 한 번에 30명까지 탑승할 수 있습니다. 1284명의 승객을 모두 한 번씩 태우기 위해서는 버스는 적어도 몇 번 운행해야 합니까?

Answer: 43

Solution (Python):
var_a = 1284
var_b = 30
var_c = var_a / var_b
var_d = 1
var_e=int(((var_c+9*10**(var_d-2))//(10**(var_d-1)))*10**(var_d-1))

print(int(var_e))
Category: Arithmetic calculation

Question (EN): This year, Yuna is 12 years old and her grandmother is 72 years old. When grandmother's age is 7 times Yuna's age, how old is her grandmother?
Question (KO): 올해 유나는 12살이고 할머니는 72살입니다. 할머니 나이가 유나 나이의 7배가 될 때, 할머니 나이는 몇 살입니까?

Answer: 70

Solution (Python):
var_a = 72
var_b = 12
var_c = var_a - var_b
var_d = 7
var_e = var_c * var_d
var_f = 7
var_g = 1
var_h = var_f - var_g
var_i = var_e / var_h
print(int(var_i))
Category: Arithmetic calculation

Question (EN): You are going to put 20 bandages 15.25 centimeters (cm) in length, overlapping each other. How many centimeters (cm) must each bandage be overlapped so that the total length of the bandages is 248 centimeters (cm)?
Question (KO): 길이가 15.25 센티미터(㎝) 인 붕대 20 장을 겹치게 이어 붙이려고 합니다. 이어 붙인 붕대의 전체 길이가 248 센티미터(㎝) 가 되도록 하려면 각 붕대를 몇 센티미터(㎝) 씩 겹치게 이어 붙여야 합니까?

Answer: 3

Solution (Python):
var_a = 15.25
var_b = 248
var_c = 15.25
var_d = var_b - var_c
var_e = 20
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))