philschmid/DMath huggingface dataset:
Category: Comparison

Question (EN): There are 4 vases, (a), (b), (c), and (d). Vase (c) is larger than vase (a). Vase (d) is smaller than vase (a). Vase (c) is smaller than vase (b). What is the largest vase?
Question (KO): (가), (나), (다), (라) 4개의 꽃병이 있습니다. (다) 꽃병은 (가) 꽃병보다 큽니다. (라) 꽃병은 (가) 꽃병보다 작습니다. (다) 꽃병은 (나) 꽃병보다 작습니다. 크기가 가장 큰 꽃병은 무엇입니까?

Answer: (b)

Solution (Python):
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 = '(c)'
var_f = '(a)'
var_g = '>'
var_h = '(d)'
var_i = '(a)'
var_j = '<'
var_k = '(c)'
var_l = '(b)'
var_m = '<'
list_b= []
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()
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_n = 1
var_o = list_c[var_n-1]
print(var_o)
Category: Correspondence

Question (EN): Hansoo multiplied the value by 7, which should have been divided by 7, by mistake. So he submitted the wrong answer of 115.15. What should be the correct answer to the problem?
Question (KO): 한수는 시험에서 7로 나누어야하는 문제를 잘못보고 곱하여서 115.15라는 답을 제출했다. 한수가 푼 문제의 정답은 얼마인가?

Answer: 2.35

Solution (Python):
var_a = 115.15
var_b = 7
var_c = var_a / var_b
var_d = 7
var_e = var_c / var_d
print('{:.2f}'.format(round(var_e+1e-10,2)))
Category: Comparison

Question (EN): Find the difference between the largest and the smallest of the four numbers 2.5, 22/13, 0.7, and 32/33.
Question (KO): 네 수 중 가장 큰 것과 작은 것의 차를 구하시오. 2.5 , 22/13, 0.7, 32/33.

Answer: 1.8

Solution (Python):
var_a = 2.5
var_b = 1.6923076923076923
var_c = 0.7
var_d = 0.9696969696969697
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 = 1
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('{:.2f}'.format(round(var_i+1e-10,2)))
Category: Arithmetic calculation

Question (EN): What is the smallest natural number greater than 12?
Question (KO): 12보다 큰 자연수 중에서 가장 작은 자연수는 얼마인지 구하시오

Answer: 13

Solution (Python):
var_a = 12
var_b = 1
var_c = var_a + var_b
var_d = 999
var_e = 1
list_a = [i for i in range(var_c, var_d + 1, var_e)]
var_f = 1
list_b=list_a.copy()
list_b.sort()
var_g = list_b[var_f-1]
print(int(var_g))
Category: Possibility

Question (EN): How many faces of a cube-shaped box meet at one vertex?
Question (KO): 정육면체 모양의 상자에서 한 꼭짓점에 모인 면의 개수는 몇 개 일까요?

Answer: 3

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

Question (EN): The white chest of drawers has a volume of 2 cubic meters (m3) and the black chest of drawers has a volume of 85000 cubic centimeters (cm3). Which color chest of drawers is more bulky?
Question (KO): 흰색 서랍장의 부피는 2세제곱미터(㎥)이고 검정색 서랍장의 부피는 85000세제곱센티미터(㎤)입니다. 둘 중 부피가 큰 서랍장의 색깔은 무엇입니까?

Answer: white

Solution (Python):
var_a = 'white'
var_b = 'black'
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 = 850000
var_e = 100
var_f = 3
var_g = var_e ** var_f
var_h = var_d / var_g
list_b= []
if "/" in str(var_h):
    var_h = eval(str(var_h))
list_b.append(var_h)
if "/" in str(var_c):
    var_c = eval(str(var_c))
list_b.append(var_c)
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)
Category: Arithmetic calculation

Question (EN): Mathematics is 82 points, Korean language is 5 points higher. If the average score in Korean, English, and Mathematics is 89, what is the English score?
Question (KO): 수학이 82점이고 국어는 5점 더 높다. 국어, 영어, 수학의 평균이 89점일 때 영어는 몇 점인가?

Answer: 98

Solution (Python):
var_a = 89
var_b = 3
var_c = var_a * var_b
var_d = 82
var_e = var_c - var_d
var_f = 82
var_g = 5
var_h = var_f + var_g
var_i = var_e - var_h
print(int(var_i))
Category: Arithmetic calculation

Question (EN): There are 62 marbles. Add a few more marbles and you'll have no leftover and hand it out equally to 8 people. Find the minimum number of marbles required.
Question (KO): 구슬이 62개 있습니다. 몇 개의 구슬을 더하면 남는 것 없이 8명에게 똑같이 나누어 줄 수 있습니다. 필요한 구슬의 최소 개수를 구하시오.

Answer: 2

Solution (Python):
var_a = 8
var_b = 62
var_c = 8
var_d = var_b % var_c
var_e = var_a - var_d
print(int(var_e))
Category: Correspondence

Question (EN): You have to add 40 to a number. But you divided a number by 6 by mistake and obtained a result of 52. What is the correct result of the calculation?
Question (KO): 40을 어떤 수에 더해야 할 것을 잘못하여 6을 어떤 수에 나눈 결과는 52가 나옵니다. 바르게 계산하면 얼마인가요?

Answer: 352

Solution (Python):
var_a = 52
var_b = 6
var_c = var_a * var_b
var_d = 40
var_e = var_c + var_d
print(int(var_e))
Category: Arithmetic calculation

Question (EN): Taeyang's school decided to rent a bus to go on a school trip. When a bus can accommodate up to 30 students, how many buses should the school rent to accommodate all 1284 students?
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: Possibility

Question (EN): Write down the 3rd smallest number among four-digit numbers that can be formed from four different numbers among 5, 0, 1, 8, and 7.
Question (KO): 5, 0, 1, 8, 7 중에서 서로 다른 숫자 4개를 뽑아 만들 수 있는 네 자리 수 중에서 3번째로 작은 수를 쓰시오.

Answer: 1075

Solution (Python):
var_a = 5
var_b = 0
var_c = 1
var_d = 8
var_e = 7
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 = 4
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 = 3
list_c=list_b.copy()
list_c.sort()
var_h = list_c[var_g-1]
print(int(var_h))
Category: Arithmetic calculation

Question (EN): There are four numbers 10, 11, 12, and 13. What is the product of the largest number and the next largest number?
Question (KO): 4개의 수 10, 11, 12, 13이 있습니다. 그 중에서 가장 큰 수와 그 다음으로 큰 수의 곱은 얼마입니까?

Answer: 156

Solution (Python):
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 = 1
list_b=list_a.copy()
list_b.sort()
var_f = list_b[-var_e]
var_g = 2
list_c=list_a.copy()
list_c.sort()
var_h = list_c[-var_g]
var_i = var_f * var_h
print(int(var_i))
Category: Arithmetic calculation

Question (EN): The students are standing in eight rows. Among them, there are six people standing in each of the seven rows, and five people are standing in last row. How many students are there in total?
Question (KO): 학생들이 8줄로 서 있습니다. 그중에서 7개의 줄에는 6명씩 서 있고, 나머지 1줄에는 5명이 서 있습니다. 학생들은 모두 몇 명입니까?

Answer: 47

Solution (Python):
var_a = 7
var_b = 6
var_c = var_a * var_b
var_d = 1
var_e = 5
var_f = var_d * var_e
var_g = var_c + var_f
print(int(var_g))
Category: Possibility

Question (EN): We want to create a four-digit number using the five numbers 2, 0, 3, 5, and 8. Find the difference between the largest and smallest possible numbers.
Question (KO): 5개의 숫자 2, 0, 3, 5, 8을 이용하여 네 자리 수를 만들고자 한다. 만들 수 있는 수 중 가장 큰 수와 가장 작은 수의 차이를 구하시오.

Answer: 6497

Solution (Python):
var_a = 2
var_b = 0
var_c = 3
var_d = 5
var_e = 8
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 = 4
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 = 1
list_c=list_b.copy()
list_c.sort()
var_h = list_c[-var_g]
var_i = 1
list_d=list_b.copy()
list_d.sort()
var_j = list_d[var_i-1]
var_k = var_h - var_j
print(int(var_k))
Category: Comparison

Question (EN): Two boxes (A), (B) have been delivered. Jimin tries to carry the smaller of the two boxes. If box (A) is smaller than box (B), which box does Jimin have to carry?
Question (KO): (가), (나) 2개의 상자가 배달왔습니다. 지민이는 두 상자 중 작은 상자를 들고 가려고 합니다. (가) 상자보다 (나) 상자가 작았다면, 지민이가 들고가야 하는 상자는 무엇입니까?

Answer: (B)

Solution (Python):
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 = '(A)'
var_d = '(B)'
var_e = '>'
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)
if "/" in str(var_c):
    var_c = eval(str(var_c))
list_b.append(var_c)
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_f = len(list_c)
var_g = list_c[var_f-1]
print(var_g)
Category: Correspondence

Question (EN): When 23 is divided by 6, the quotient and remainder are A and 5, respectively. Find A at here.
Question (KO): 23를 6으로 나누면 몫과 나머지가 각각 A와 5가 나옵니다. 이 때 A를 구하시오.

Answer: 3

Solution (Python):
var_a = 23
var_b = 5
var_c = var_a - var_b
var_d = 6
var_e = var_c / var_d
print(int(var_e))
Category: Correspondence

Question (EN): When AB2-41=591, find A.
Question (KO): AB2-41=591일 때, A를 구하시오.

Answer: 6

Solution (Python):
var_a = 'AB2-41=591'
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))
Category: Comparison

Question (EN): Suhyeon, Somin, and Jisoo received the same amount of math homework. The number of math problems remaining after the three solved them is 1/4 for Sohyeon, 1/8 for Somin, and 1/5 for Jisoo. Who currently has the highest amount of problems solved?
Question (KO): 소현, 소민, 지수는 같은 양의 수학 숙제를 받았습니다. 세 사람이 풀고 남은 수학 문제의 수가 수현이는 전체의 1/4, 소민이는 전체의 1/8, 지수는 전체의 1/5입니다. 현재 가장 많은 양의 문제를 푼 사람은 누구입니까?

Answer: Somin

Solution (Python):
var_a = 'Suhyeon'
var_b = 'Somin'
var_c = 'Jisoo'
list_a= []
if "/" in str(var_c):
    var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
    var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
    var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_d = 1
var_e = 0.25
var_f = var_d - var_e
var_g = 1
var_h = 0.125
var_i = var_g - var_h
var_j = 1
var_k = 0.2
var_l = var_j - var_k
list_b= []
if "/" in str(var_l):
    var_l = eval(str(var_l))
list_b.append(var_l)
if "/" in str(var_i):
    var_i = eval(str(var_i))
list_b.append(var_i)
if "/" in str(var_f):
    var_f = eval(str(var_f))
list_b.append(var_f)
list_b.reverse()
var_m = 1
list_c=list_b.copy()
list_c.sort()
var_n = list_c[-var_m]
var_o = list_b.index(var_n)+1
var_p = list_a[var_o-1]
print(var_p)
Category: Arithmetic calculation

Question (EN): If the sum of three consecutive even numbers is 1194, what is the sum of the smallest and largest even numbers?
Question (KO): 연속된 짝수 3개의 합이 1194일 때, 가장 작은 짝수와 가장 큰 짝수의 합은 얼마입니까?

Answer: 796

Solution (Python):
var_a = 1194
var_b = 0
var_c = 3
var_d = 1
var_e = var_c - var_d
var_f = 2
var_g = var_e * var_f
var_h = 2
list_a = [i for i in range(var_b, var_g + 1, var_h)]
list_a = [float(i) for i in list_a]
var_i = sum(list_a)
var_j = var_a - var_i
var_k = 3
var_l = var_j / var_k
var_m = 2
var_n = var_l * var_m
var_o = 3
var_p = 1
var_q = var_o - var_p
var_r = 2
var_s = var_q * var_r
var_t = var_n + var_s
print(int(var_t))
Category: Comparison

Question (EN): Minho's age is three times Suhong's age, and Mina's age is two years younger than twice the Suhong's age. If the sum of the ages of the three is 34, how old is Mina?
Question (KO): 민호의 나이는 수홍이의 나이의 3배이고, 민아의 나이는 수홍이의 나이의 2배보다 2살 적습니다. 세 사람의 나이의 합이 34살일 때, 민아의 나이는 몇 살인지 구하시오.

Answer: 10

Solution (Python):
var_a = 34
var_b = 2
var_c = var_a + var_b
var_d = 3
var_e = 1
var_f = var_d + var_e
var_g = 2
var_h = var_f + var_g
var_i = var_c / var_h
var_j = 2
var_k = var_i * var_j
var_l = 2
var_m = var_k - var_l
print(int(var_m))
Category: Correspondence

Question (EN): There are two different numbers A and B. Find the difference between A and B in the multiplication equation AB×6=BBB.
Question (KO): 서로 다른 두 수 A, B가 있습니다. 곱셈식 AB×6=BBB에서 A와 B의 차를 구하시오.

Answer: 3

Solution (Python):
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
var_h = abs(var_g)
print(int(var_h))
Category: Possibility

Question (EN): 1, 2, 3, 4 ..., 998, 999 were written sequentially to make 1234567891011121314...998999. Find the sum of each digit in this number.
Question (KO): 1, 2, 3, 4 ..., 998, 999를 차례로 이어 써서 1234567891011121314...998999를 만들었다. 이 수의 각 자리 숫자들의 총합을 구하여라.

Answer: 13500

Solution (Python):
var_a = 1
var_b = 999
var_c = 1
list_a = [i for i in range(var_a, var_b + 1, var_c)]
list_b=[]
for i in list_a:
    var_d = 0
    i = int(i)
    while i//10 > 0:
        var_d = var_d + i%10
        i = i//10
    var_d = var_d + i%10
    list_b.append(var_d)
list_b = [float(i) for i in list_b]
var_e = sum(list_b)
print(int(var_e))
Category: Arithmetic calculation

Question (EN): Hyunseo wants to exchange Korean money for Chinese money. It takes 161.5 Korean won to get 1 Chinese yuan. If you want to change 170,000 won in Korean money into 1000 yuan and 10 yuan in Chinese money, find how many 10 yuan you can get when you exchange as many 1000 yuan as possible.
Question (KO): 현서는 우리나라 돈을 중국 돈으로 환전하려고 합니다. 중국 돈 1위안을 얻으려면 우리나라 돈 161.5원이 필요합니다. 우리나라 돈 17만원을 중국 돈 1000위안과 10위안으로 바꾸려 할 때, 1000위안으로 최대한 많이 바꾼다면 10위안은 몇 장으로 바꿀 수 있는 지 구하세요.

Answer: 5

Solution (Python):
var_a = 17
var_b = 10000
var_c = var_a * var_b
var_d = 161.5
var_e = 1000
var_f = var_d * var_e
var_g = var_c % var_f
var_h = 161.5
var_i = 10
var_j = var_h * var_i
var_k = var_g // var_j
print(int(var_k))
Category: Arithmetic calculation

Question (EN): If Yoongi's initial money is 3,800 won, and he receives 100 won every day from today, how much money will he have after 7 days?
Question (KO): 처음 윤기가 가지고 있는 돈이 3800원일때, 오늘부터 매일 100원씩 받으면 7일후에 윤기가 가지고 있는 돈은 모두 얼마가 됩니까?

Answer: 4500

Solution (Python):
var_a = 3800
var_b = 100
var_c = 7
var_d = var_b * var_c
var_e = var_a + var_d
print(int(var_e))
Category: Comparison

Question (EN): The auditorium of Seoyoon's school is 1105 square meters (㎡), and the school has 650 students. The auditorium of Yerim's school is measured as 1440 square meters (㎡), and 960 students are attending the school. Which school has a larger auditorium per student?
Question (KO): 서윤이네 학교의 강당은 1105제곱미터(㎡)이며 학생 수는 650명입니다. 예림이네 학교의 강당은 1440제곱미터(㎡)이며 학생 수는 960 명입니다. 한 명당 사용하는 강당의 넓이가 더 넓은 학교는 누구네 학교입니까?

Answer: Seoyoon

Solution (Python):
var_a = 'Seoyoon'
var_b = 'Yerim'
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 = 1105
var_d = 650
var_e = var_c / var_d
var_f = 1440
var_g = 960
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)
Category: Correspondence

Question (EN): When 25 is divided by 4, the quotient is A and the remainder is B. What is A in this case?
Question (KO): 25를 4로 나눴을 때 몫이 A, 나머지가 B 였습니다. 이 때 A는 무엇인가요?

Answer: 6

Solution (Python):
var_a = 25
var_b = 4
var_c = var_a // var_b
print(int(var_c))
Category: Correspondence

Question (EN): Adding 34 to a certain number and subtracting 53 results in 28. Find the certain number.
Question (KO): 어떤 수에 34를 더하고 53을 뺐더니 28이 되었습니다. 어떤 수를 구하시오.

Answer: 47

Solution (Python):
var_a = 28
var_b = 53
var_c = var_a + var_b
var_d = 34
var_e = var_c - var_d
print(int(var_e))
Category: Arithmetic calculation

Question (EN): If 1 blue ball is removed from a box containing 3 red balls, 2 blue balls, and 5 yellow balls, what is the number of yellow balls?
Question (KO): 빨간 공 3개, 파란 공 2개, 노란 공 5개가 담겨져 있는 상자에서 파란 공 1개를 뺐을 때, 노란 공의 개수는?

Answer: 5

Solution (Python):
var_a = 5
print(int(var_a))