philschmid/DMath huggingface dataset:
Category: Possibility

Question (EN): There are toys with 1, 6 and 8 drawn on them. Let's say the first one Rowoon chooses is the hundred's place, the second is the tens' place, and the third is the ones' place. Find the sum of the largest number and the third largest number that Rowoon can make. However, Rowwon cannot select the same toy multiple times.
Question (KO): 1, 6, 8이 그려진 장난감이 있습니다. 로운이가 처음 고르는 것을 백의 자리, 두 번째는 십의 자리, 세 번째는 일의 자리라고 할 때, 로운이가 만들 수 있는 수 중 가장 큰 수와 세 번째로 큰 수의 합을 구하시오. 단, 같은 장난감을 여러 번 고를 수 없습니다.

Answer: 1542

Solution (Python):
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 = 1
list_c=list_b.copy()
list_c.sort()
var_f = list_c[-var_e]
var_g = 3
list_d=list_b.copy()
list_d.sort()
var_h = list_d[-var_g]
var_i = var_f + var_h
print(int(var_i))
Category: Comparison

Question (EN): There are red balls and blue balls in the box with blue balls being 17 more than the red balls. Minsu put in 57 blue balls and 18 red balls and subtracted 44 balls. When you checked the inside of the box and there were 502 balls in total, find the number of blue balls that were in the box at the beginning.
Question (KO): 상자 안에 빨간공과 빨간공 보다 17개 더 많은 파란공이 있습니다. 민수가 파란공 57개, 빨간공 18개를 넣고 44개를 뺐습니다. 상자 안을 확인해보니 총 502개의 공이 있었을 때, 처음 상자 안에 있던 파란공의 개수를 구하시오.

Answer: 244

Solution (Python):
var_a = 502
var_b = 18
var_c = 57
var_d = var_b + var_c
var_e = 44
var_f = var_d - var_e
var_g = var_a - var_f
var_h = 17
var_i = var_g + var_h
var_j = 2
var_k = var_i / var_j
print(int(var_k))
Category: Arithmetic calculation

Question (EN): Taehong's distance from school to home is 460 meters (m) farther than Jiwon's. If the distance from Taehong's house to the school is 1.05 kilometers (km), how many kilometers (km) is it from Jiwon's house to the school?
Question (KO): 태홍이는 지원이보다 학교에서 집까지의 거리가 460미터(m) 멉니다. 태홍이네 집에서 학교까지의 거리가 1.05킬로미터(㎞)일 때, 지원이네 집에서 학교까지는 몇 킬로미터(㎞)입니까?

Answer: 0.59

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

Question (EN): If the weight of the heavy box is 14/15 kg (kg), and the light box is 1/10 kg (kg) lighter than the heavy box, find the sum of the weights of the two boxes in kg (kg).
Question (KO): 무거운 상자의 무게가 14/15킬로그램(㎏)이고, 가벼운 상자의 무게는 무거운 상자의 무게보다 1/10킬로그램(㎏) 더 가볍다면 이때 두 상자의 무게의 합은 몇 킬로그램(㎏)인지 구하시오.

Answer: 1.77

Solution (Python):
var_a = 0.9333333333333333
var_b = 2
var_c = var_a * var_b
var_d = 0.1
var_e = var_c - var_d
print('{:.2f}'.format(round(var_e+1e-10,2)))
Category: Possibility

Question (EN): How many three-digit numbers are there where the sum of all the digits is 25?
Question (KO): 모든 자리 수의 합이 25인 세 자리 수는 모두 몇 개입니까?

Answer: 6

Solution (Python):
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)]
list_b=[]
for i in list_a:
    var_f = 0
    i = int(i)
    while i//10 > 0:
        var_f = var_f + i%10
        i = i//10
    var_f = var_f + i%10
    list_b.append(var_f)
var_g = 25
list_c = []
for i in list_b:
    if i >= var_g:
        list_c.append(i)
var_h = 25
list_d = []
for i in list_c:
    if i <= var_h:
        list_d.append(i)
var_i = len(list_d)
print(int(var_i))
Category: Arithmetic calculation

Question (EN): There are five numbers 10, 11, 12, 13, and 14. What is the quotient when you divide the largest number by the second smallest number?
Question (KO): 5개의 수 10, 11, 12, 13, 14가 있습니다. 그 중에서 가장 큰 수를 2번째로 작은 수로 나눈 몫은 얼마입니까?

Answer: 1

Solution (Python):
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 = 1
list_b=list_a.copy()
list_b.sort()
var_g = list_b[-var_f]
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))
Category: Comparison

Question (EN): There are a total of 4 numbers: 0.8, 1/2, 0.5, and 1/3. What is the smallest of these numbers greater than 0.1?
Question (KO): 총 4개의 숫자 0.8, 1/2, 0.5, 1/3이 있습니다. 이 중 0.1보다 큰 수 중 가장 작은 수를 구하면 무엇인가요?

Answer: 0.33

Solution (Python):
var_a = 0.8
var_b = 0.5
var_c = 0.5
var_d = 0.3333333333333333
list_a= []
if "/" in str(var_d):
    var_d = eval(str(var_d))
list_a.append(var_d)
if "/" in str(var_c):
    var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
    var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
    var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_e = 0.1
list_b = []
for i in list_a:
    if i > var_e:
        list_b.append(i)
var_f = 1
list_c=list_b.copy()
list_c.sort()
var_g = list_c[var_f-1]
print('{:.2f}'.format(round(var_g+1e-10,2)))
Category: Comparison

Question (EN): Sora collected 4 and 6. Heesu collected 7 and 5, and Jiyeon collected 3 and 8. Who has the greatest sum of numbers?
Question (KO): 소라는 4와 6을 모았습니다. 희수는 7과 5를 모았고, 지연이는 3과 8을 모았습니다. 모은 수의 합이 가장 큰 사람은 누구입니까?

Answer: Heesu

Solution (Python):
var_a = 'Sora'
var_b = 'Heesu'
var_c = 'Jiyeon'
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 = var_d + var_e
var_g = 7
var_h = 5
var_i = var_g + var_h
var_j = 3
var_k = 8
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: Possibility

Question (EN): You want to create a two-digit number by drawing two different numbers from 1, 2, 4, and 6. Find the largest number among them.
Question (KO): 서로 다른 숫자 2개를 1, 2, 4, 6 중에서 뽑아 두 자리 수를 만들려고 합니다. 그 중 가장 큰 수를 구하시오.

Answer: 64

Solution (Python):
var_a = 1
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 = 2
list_b = [str(i) for i in list_a]
list_b = list(itertools.permutations(list_b, var_e))
list_b = [''.join(num_list) for num_list in list_b]
list_b = [str_num for str_num in list_b if str_num[0] != '0']
list_b = [float(i) for i in list_b]
var_f = 1
list_c=list_b.copy()
list_c.sort()
var_g = list_c[-var_f]
print(int(var_g))
Category: Geometry

Question (EN): You have a rectangle with a width of 6 centimeters (cm) and a perimeter of 28 centimeters (cm). What is the area of this rectangle?
Question (KO): 가로가 6센티미터(㎝), 둘레가 28 센티미터(㎝)인 직사각형이 있습니다. 이 직사각형의 넓이는?

Answer: 48

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

Question (EN): Both sides of an isosceles triangle are 12 centimeters (cm) long, and the other side is 17 centimeters (cm) long. What is the perimeter of this isosceles triangle in centimeters (cm)?
Question (KO): 이등변삼각형의 양변의 길이가 12 센티미터(㎝)이며, 나머지 변의 길이가 17 센티미터(㎝)입니다. 이 이등변삼각형의 둘레의 길이는 몇 센티미터(㎝)일까요?

Answer: 41

Solution (Python):
var_a = 12
var_b = 2
var_c = var_a * var_b
var_d = 17
var_e = var_c + var_d
print(int(var_e))
Category: Comparison

Question (EN): Try to find the smallest animal among (a), (b), (c), and (d). (d) is smaller than (a), (b) is larger than (c) and is smaller than (d). What is the answer?
Question (KO): (가), (나), (다), (라) 중 가장 작은 동물을 찾으려 한다. (라)는 (가)보다 작고 (나)는 (다)보다 크며 (라)보다 작다. 답은 무엇인가?

Answer: (c)

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

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

Answer: 10

Solution (Python):
var_a = 6
var_b = 2
var_c = var_a ** var_b
var_d = 8
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): When two out of five cards with the numbers 0, 1, 2, 3, and 4 written on them are drawn to form two-digit integers, find how many even numbers there are.
Question (KO): 0, 1, 2, 3, 4의 수가 각각 적힌 5장의 카드에서 2장을 뽑아 두 자리 정수를 만들 때 짝수는 모두 몇 개인지 구하시오

Answer: 10

Solution (Python):
var_a = 0
var_b = 1
var_c = 2
var_d = 3
var_e = 4
list_a= []
if "/" in str(var_e):
    var_e = eval(str(var_e))
list_a.append(var_e)
if "/" in str(var_d):
    var_d = eval(str(var_d))
list_a.append(var_d)
if "/" in str(var_c):
    var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
    var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
    var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_f = 2
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 = 2
list_c = []
var_g = int(var_g)
for i in list_b:
    i = int(i)
    if i % var_g == 0:
        list_c.append(i)
var_h = len(list_c)
print(int(var_h))
Category: Comparison

Question (EN): Yoongi has 4 apples and Jungkook has 6 divided by 3 apples. Who has the greater number of apples?
Question (KO): 윤기는 4개, 정국이는 6 나누기 3만큼 사과를 가졌습니다. 사과의 개수가 더 큰 사람은 누구입니까?

Answer: Yoongi

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: Correspondence

Question (EN): Hoseok multiplied a certain number by 11 and the result was 99. What is the certain number?
Question (KO): 호석이는 어떤 수에 11을 곱해 99를 얻었습니다. 어떤 수는 얼마일까요?

Answer: 9

Solution (Python):
var_a = 99
var_b = 11
var_c = var_a / var_b
print(int(var_c))
Category: Correspondence

Question (EN): When 10+A=15, find the correct number for A.
Question (KO): 10+A=15일 때, A에 들어가야 하는 숫자를 구하시오

Answer: 5

Solution (Python):
var_a = '10+A=15'
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: Correspondence

Question (EN): When AB+13=64, what number should go in A?
Question (KO): AB+13=64일 때, A에 들어가야 하는 숫자는 무엇인가요?

Answer: 5

Solution (Python):
var_a = 'AB+13=64'
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: Geometry

Question (EN): Hyewon made pentagonal pillars with clay during art class and painted each side with a different color. How many colors did Hyewon paint on the pentagonal pillar?
Question (KO): 혜원이는 미술 시간에 찰흙을 가지고 오각기둥을 만든 후 각각의 면에 서로 다른 색을 칠하였습니다. 혜원이가 오각 기둥에 칠한 색은 모두 몇 가지 입니까?

Answer: 7

Solution (Python):
var_a = 2
var_b = 5
var_c = var_a + var_b
print(int(var_c))
Category: Correspondence

Question (EN): This year, 273 more students transferred from Seoul to Gyeonggi-do than vice versa. This year, there were 477 more students attending schools in Gyeonggi-do than students attending schools in Seoul. Find how many people were different last year.
Question (KO): 올해 서울에서 경기도로 전학 간 학생이 그 반대의 경우보다 273명 많았다. 올해 경기도에서 학교를 다니는 학생이 서울에서 학교를 다니는 학생보다 477명 많았다. 작년에는 차이가 몇 명이었는지 구하시오.

Answer: 1023

Solution (Python):
var_a = 477
var_b = 273
var_c = var_a + var_b
var_d = 273
var_e = var_c + var_d
print(int(var_e))
Category: Arithmetic calculation

Question (EN): We are trying to fill a bathtub with a capacity of 140 liters (l) with a tap that produces 15 liters (l) of water in 3 minutes at a constant speed. How many minutes should I get water to fill this bathtub?
Question (KO): 일정한 빠르기로 3분 동안 15리터(L)의 물이 나오는 수도로 들이가 140리터(L)인 욕조에 물을 가득 채우려고 합니다. 몇 분 동안 물을 받아야 합니까?

Answer: 28

Solution (Python):
var_a = 140
var_b = 15
var_c = 3
var_d = var_b / var_c
var_e = var_a / var_d
print(int(var_e))
Category: Correspondence

Question (EN): When Minyoung divided 107.8 by a certain number, it became 9.8. Find out what the number is.
Question (KO): 민영이가 107.8 을 어떤 수로 나누었더니 9.8 이 되었습니다. 어떤 수는 얼마인지 구하시오.

Answer: 11

Solution (Python):
var_a = 107.8
var_b = 9.8
var_c = var_a / var_b
print(int(eval('{:.2f}'.format(round(var_c+1e-10,2)))))
Category: Comparison

Question (EN): A triangle has a base of 10 centimeters (cm) and a height of 11 centimeters (cm). There is a square with a width of 8 centimeters (cm) and a length of 8 centimeters (cm), and the diameter of a circle is 8 centimeters (cm). Which shape has the widest area? Calculate the circumference ratio as 3.1.
Question (KO): 삼각형은 밑변이 10센티미터(cm)이고 높이가 11센티미터(cm)입니다. 정사각형은 가로가 8센티미터(cm) 세로가 8센티미터(cm)이고, 원의 지름은 8센티미터(cm)입니다. 가장 넓이가 넓은 도형은 무엇입니까? 원주율은 3.1로 계산하세요.

Answer: square

Solution (Python):
var_a = 'triangle'
var_b = 'square'
var_c = 'circle'
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 = 11
var_f = var_d * var_e
var_g = 2
var_h = var_f / var_g
var_i = 8
var_j = 2
var_k = var_i ** var_j
var_l = 8
var_m = 2
var_n = var_l / var_m
var_o = 2
var_p = var_n ** var_o
var_q = 3.1
var_r = var_p * var_q
list_b= []
if "/" in str(var_r):
    var_r = eval(str(var_r))
list_b.append(var_r)
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_s = 1
list_c=list_b.copy()
list_c.sort()
var_t = list_c[-var_s]
var_u = list_b.index(var_t)+1
var_v = list_a[var_u-1]
print(var_v)
Category: Comparison

Question (EN): In the running match, Taehyung did better than Jungkook and worse than Minyeong. If Minyoung is 5th and Jungkook is 7th, what rank is Taehyung?
Question (KO): 달리기 시합에서 태형이는 정국이보다 잘했고 민영이보다는 못했습니다. 민영이가 5등이고 정국이가 7등을 했을때 태형이는 몇 등입니까?

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
print(int(var_e))
Category: Possibility

Question (EN): By using 5, 1, 7, 6, and a decimal point only once each, how many decimal numbers greater than 7 with three decimal places can you make?
Question (KO): 5, 1, 7, 6과 소수점을 한 번씩만 사용하여 7보다 큰 소수 세 자리 수를 모두 몇 개 만들 수 있습니까?

Answer: 6

Solution (Python):
var_a = 5
var_b = 1
var_c = 7
var_d = 6
list_a= []
if "/" in str(var_d):
    var_d = eval(str(var_d))
list_a.append(var_d)
if "/" in str(var_c):
    var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
    var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
    var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_e = 4
list_b = [str(i) for i in list_a]
list_b = list(itertools.permutations(list_b, var_e))
list_b = [''.join(num_list) for num_list in list_b]
list_b = [str_num for str_num in list_b if str_num[0] != '0']
list_b = [float(i) for i in list_b]
var_f = 7
var_g = 10
var_h = 4
var_i = 1
var_j = var_h - var_i
var_k = var_g ** var_j
var_l = var_f * var_k
list_c = []
for i in list_b:
    if i > var_l:
        list_c.append(i)
var_m = len(list_c)
print(int(var_m))
Category: Comparison

Question (EN): 20 different cars are parked in a row. If the black car is 16th from the right and the white car is 11th from the left, how many total cars are parked between the two cars?
Question (KO): 서로 다른 자동차 20대가 한 줄로 주차되어 있다. 검은색 자동차는 오른쪽에서 16번째에, 흰색 자동차는 왼쪽에서 11번째에 있을 때, 두 자동차 사이에 주차되어 있는 자동차는 총 몇대인가?

Answer: 5

Solution (Python):
var_a = 16
var_b = 11
var_c = var_a + var_b
var_d = 20
var_e = var_c - var_d
var_f = 2
var_g = var_e - var_f
print(int(var_g))
Category: Arithmetic calculation

Question (EN): Minjeong and Soohyeok's piggy banks currently contain 8,000 won and 5,000 won, respectively. If Minjeong puts 300 won and Soohyeok puts 500 won into their piggy bank every day, starting tomorrow, how many days later will the money in Minjeong's and Soohyeok's piggy banks become the same?
Question (KO): 민정이와 수혁이의 저금통에는 현재 각각 8000원, 5000원이 들어 있다. 내일부터 매일 민정이는 300원씩, 수혁이는 500원씩 저금통에 넣는다면, 민정이와 수혁이의 저금통에 들어 있는 금액이 같아지는 것은 며칠 후인가?

Answer: 15

Solution (Python):
var_a = 8000
var_b = 5000
var_c = var_a - var_b
var_d = 500
var_e = 300
var_f = var_d - var_e
var_g = var_c / var_f
print(int(var_g))
Category: Geometry

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

Answer: 5

Solution (Python):
var_a = 13
var_b = 2
var_c = var_a ** var_b
var_d = 12
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: Correspondence

Question (EN): When a number is divided by 23, the quotient is 17 and the remainder is 19. When this number is multiplied by 10 and then divided by 23, find the sum of its quotient and remainder.
Question (KO): 어떤 수를 23으로 나누면 몫은 17이고 나머지가 19입니다. 이 어떤 수를 10배 한 수를 23으로 나누었을 때의 몫과 나머지의 합을 구하시오.

Answer: 184

Solution (Python):
var_a = 23
var_b = 17
var_c = var_a * var_b
var_d = 19
var_e = var_c + var_d
var_f = 10
var_g = var_e * var_f
var_h = 23
var_i = var_g // var_h
var_j = 23
var_k = 17
var_l = var_j * var_k
var_m = 19
var_n = var_l + var_m
var_o = 10
var_p = var_n * var_o
var_q = 23
var_r = var_p % var_q
var_s = var_i + var_r
print(int(var_s))
Category: Arithmetic calculation

Question (EN): There were 1238 apples and 374 more pears than apples in the fruit shop. Of these, a few apples were sold, and 276 pears were bought, so the total of apples and pears was 2527. How many apples have been sold?
Question (KO): 과일 가게에 사과가 1238개, 배는 사과보다 374개 더 많이 있었습니다. 이 중에서 사과 몇 개가 팔리고, 배 276개를 사들였더니 사과와 배를 합하여 2527개가 되었습니다. 팔린 사과는 몇 개입니까?

Answer: 599

Solution (Python):
var_a = 1238
var_b = 2527
var_c = 1238
var_d = 374
var_e = var_c + var_d
var_f = 276
var_g = var_e + var_f
var_h = var_b - var_g
var_i = var_a - var_h
print(int(var_i))