philschmid/DMath huggingface dataset:
Category: Comparison

Question (EN): Yujeong arranged several colored balls on the desk. If the red, blue, yellow, purple and white balls are arranged in this order, what color is the first ball?
Question (KO): 유정은 책상 위에 색색의 공을 여러 개 늘어놓았다. 빨간색, 파란색, 노란색, 보라색, 흰색 공을 배열할 때 첫 번째 공은 무슨 색입니까?

Answer: red

Solution (Python):
var_a = 'red'
var_b = 'blue'
var_c = 'yellow'
var_d = 'purple'
var_e = 'white'
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
var_g = list_a[var_f-1]
print(var_g)
Category: Geometry

Question (EN): Find the length in centimeters (cm) of a side of an equilateral triangle with length 9/20 centimeters (cm) and a regular pentagon with the same perimeter.
Question (KO): 한 변의 길이가 9/20 센티미터(㎝)인 정삼각형과 둘레가 같은 정오각형의 한 변의 센티미터(㎝) 길이를 구하십시오.

Answer: 0.27

Solution (Python):
var_a = 0.45
var_b = 3
var_c = var_a * var_b
var_d = 5
var_e = var_c / var_d
print('{:.2f}'.format(round(var_e+1e-10,2)))
Category: Correspondence

Question (EN): You should have divided a certain number by 8, but you mistakenly divided it by 6 and got a quotient of 124 and a remainder of 4. Find the answer to the correct calculation.
Question (KO): 어떤 수를 8로 나누어야 할 것을 잘못하여 6으로 나누었더니 몫이 124, 나머지가 4가 되었습니다. 바르게 계산한 결과를 구하시오.

Answer: 93.5

Solution (Python):
var_a = 124
var_b = 6
var_c = var_a * var_b
var_d = 4
var_e = var_c + var_d
var_f = 8
var_g = var_e / var_f
print('{:.2f}'.format(round(var_g+1e-10,2)))
Category: Correspondence

Question (EN): The number of first-year students attending Woojung High School is 468 less than the number of non-first-year students. If the number of non-first year students is 954, how many students attend Woojung High School?
Question (KO): 우정고등학교에 다니는 1학년 수는 1학년이 아닌 학생 수보다 468명 적다. 1학년이 아닌 학생 수가 954명이면 우정고등학교에 다니는 학생수는 몇 명인가?

Answer: 1440

Solution (Python):
var_a = 954
var_b = 468
var_c = var_a - var_b
var_d = 954
var_e = var_c + var_d
print(int(var_e))
Category: Arithmetic calculation

Question (EN): There are 68 soccer balls, which are 12 less compared to volleyballs and 23 more than basketballs. How many soccer balls, volleyballs, and basketballs are there altogether?
Question (KO): 축구공이 68개 있습니다. 축구공은 배구공보다 12개 적고, 농구공보다 23개 많습니다. 축구공, 배구공, 농구공은 모두 몇 개입니까?

Answer: 193

Solution (Python):
var_a = 68
var_b = 12
var_c = var_a + var_b
var_d = 68
var_e = 23
var_f = var_d - var_e
var_g = var_c + var_f
var_h = 68
var_i = var_g + var_h
print(int(var_i))
Category: Comparison

Question (EN): Among 1.4, 9/10, 1.2, 0.5, and 13/10, find how many numbers are less than or equal to 1.1.
Question (KO): 1.4, 9/10, 1.2, 0.5, 13/10 중에서 1.1보다 작거나 같은 수를 고르면 몇 개인지 구하시오.

Answer: 2

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

Question (EN): Three out of five digits 0, 1, 2, 3, and 4 were chosen to make a three-digit odd number. If you can use the same number multiple times, how many odd numbers can you make?
Question (KO): 다섯 개의 숫자 0, 1, 2, 3, 4 중에서 3개를 골라 세 자리의 홀수를 만들었다. 같은 수를 여러 번 사용해도 된다면, 만들 수 있는 모든 홀수의 개수는 몇개인가?

Answer: 40

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 = 3
list_b = [str(i) for i in list_a]
list_b = list(itertools.product(list_b, repeat=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)
list_d = list(set(list_b) - set(list_c))
var_h = len(list_d)
print(int(var_h))
Category: Geometry

Question (EN): Consider a rectangle whose long side is 1 meter (m) and whose short side is 2/8 meter (m) shorter than the long side. What is the sum of the lengths of the four sides of this rectangle in meters (m)?
Question (KO): 긴 변이 1미터(m)이고 짧은 변이 긴 변보다 2/8미터(m) 짧은 직사각형이 있습니다. 이 직사각형의 네 변의 길이의 합은 몇 미터(m)입니까?

Answer: 3.5

Solution (Python):
var_a = 1
var_b = 1
var_c = 2
var_d = 8
var_e = var_c / var_d
var_f = var_b - var_e
var_g = var_a + var_f
var_h = 2
var_i = var_g * var_h
print('{:.2f}'.format(round(var_i+1e-10,2)))
Category: Correspondence

Question (EN): A, B, and C are different numbers from 0 to 9. Find C from the subtraction sentence AAA-BB=AC.
Question (KO): A, B, C는 0에서 9까지의 서로 다른 숫자입니다. 뺄셈식 AAA-BB=AC에서 C를 구하시오.

Answer: 2

Solution (Python):
var_a = 'AAA-BB=AC'
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: Arithmetic calculation

Question (EN): Woo-gyeong is 9 centimeters (cm) shorter than Eun-mi. If Woo-gyeong's height is 1 meter (m) and 35 centimeters (cm), how many meters (m) is Eun-mi's height expressed as a decimal number?
Question (KO): 우경이의 키는 은미보다 9센티미터(㎝)가 작습니다. 우경이의 키가 1미터(m) 35센티미터(㎝)라면 은미의 키는 몇 미터(m)인지 소수로 나타내시오.

Answer: 1.44

Solution (Python):
var_a = 1
var_b = 35
var_c = 100
var_d = var_b / var_c
var_e = var_a + var_d
var_f = 9
var_g = 100
var_h = var_f / var_g
var_i = var_e + var_h
print('{:.2f}'.format(round(var_i+1e-10,2)))
Category: Geometry

Question (EN): You are trying to find the number of vertices of a shape. If this figure is a cube, find the number of vertices.
Question (KO): 어떤 도형의 꼭지점의 수를 구하려고 합니다. 이 도형이 정육면체일 때 꼭지점의 수를 구하시오.

Answer: 8

Solution (Python):
var_a = 6
var_b = 2
var_c = var_a - var_b
var_d = 2
var_e = var_c * var_d
print(int(var_e))
Category: Arithmetic calculation

Question (EN): There are Seoraksan, Jirisan, Hallasan, and Baekdusan. Jirisan is 207 meters (m) higher than Seoraksan. Hallasan is 252 meters (m) higher than Seoraksan. Baekdusan is 839 meters (m) higher than Jirisan. Find the difference in height between Seoraksan and Baekdusan.
Question (KO): 설악산, 지리산, 한라산, 백두산이 있습니다. 지리산은 설악산보다 207미터(m) 더 높습니다. 한라산은 설악산보다 252미터(m) 더 높습니다. 백두산은 지리산보다 839미터(m) 더 높습니다. 설악산과 백두산의 높이의 차를 구하시오.

Answer: 1046

Solution (Python):
var_a = 207
var_b = 839
var_c = var_a + var_b
print(int(var_c))
Category: Correspondence

Question (EN): When A is divided by 9, the quotient is 2 and the remainder is 6. Find out the value of A.
Question (KO): A를 9로 나누면 몫은 2이고 나머지는 6이 됩니다. A를 구하시오.

Answer: 24

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

Question (EN): There are 17 candies and two pouches with 19 candies. If you divide the candy equally among 9 people, how many can each person get?
Question (KO): 17개의 사탕, 19개의 사탕을 가진 주머니가 두개 있다. 9명에게 동일하게 사탕을 나누어 준다면 한 사람당 몇 개 가질 수 있는가?

Answer: 4

Solution (Python):
var_a = 17
var_b = 19
var_c = var_a + var_b
var_d = 9
var_e = var_c // var_d
print(int(var_e))
Category: Possibility

Question (EN): Find the number of ways in which a card numbered 1 through 9 is drawn and multiplied by 21 is greater than 84 multiplied by 2.
Question (KO): 1부터 9까지의 카드 중 하나를 뽑아서 21을 곱했을 때 84에 2를 곱한 값보다 커지는 경우의 수를 구하시오.

Answer: 1

Solution (Python):
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 = 84
var_e = 2
var_f = var_d * var_e
var_g = 21
var_h = var_f / var_g
list_b = []
for i in list_a:
    if i > var_h:
        list_b.append(i)
var_i = len(list_b)
print(int(var_i))
Category: Arithmetic calculation

Question (EN): In the set of even numbers from 600 to 800, find the sum of the digits of all the numbers in the set.
Question (KO): 600부터 800까지의 짝수들의 집합에서 집합 내의 모든 수의 각 자리 숫자들의 합은 얼마인지 구하여라.

Answer: 1508

Solution (Python):
var_a = 600
var_b = 800
var_c = 2
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: Correspondence

Question (EN): When you multiply a number by 6, you get 72. What number do you get when you add 8 to the number?
Question (KO): 어떤 수에 6을 곱했더니 72가 되었습니다. 8을 어떤 수에 더하면 얼마가 되는지 구하시오.

Answer: 20

Solution (Python):
var_a = 72
var_b = 6
var_c = var_a / var_b
var_d = 8
var_e = var_c + var_d
print(int(var_e))
Category: Comparison

Question (EN): While Toy (A) is larger than (B), it is smaller than (C). If Toy (B) is bigger than Toy (D) and Toy (C) is smaller than Toy (E), which toy is the biggest?
Question (KO): (가) 장난감은 (나) 보다 크지만 (다) 보다는 작습니다. (나) 장난감이 (라) 장난감보다 크고 (다) 장난감이 (마) 장난감보다 작다면 가장 큰 장난감은 무엇입니까?

Answer: (E)

Solution (Python):
var_a = '(A)'
var_b = '(B)'
var_c = '(C)'
var_d = '(D)'
var_e = '(E)'
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 = '(A)'
var_g = '(B)'
var_h = '>'
var_i = '(A)'
var_j = '(C)'
var_k = '<'
var_l = '(B)'
var_m = '(D)'
var_n = '>'
var_o = '(C)'
var_p = '(E)'
var_q = '<'
list_b= []
if "/" in str(var_q):
    var_q = eval(str(var_q))
list_b.append(var_q)
if "/" in str(var_p):
    var_p = eval(str(var_p))
list_b.append(var_p)
if "/" in str(var_o):
    var_o = eval(str(var_o))
list_b.append(var_o)
if "/" in str(var_n):
    var_n = eval(str(var_n))
list_b.append(var_n)
if "/" in str(var_m):
    var_m = eval(str(var_m))
list_b.append(var_m)
if "/" in str(var_l):
    var_l = eval(str(var_l))
list_b.append(var_l)
if "/" in str(var_k):
    var_k = eval(str(var_k))
list_b.append(var_k)
if "/" in str(var_j):
    var_j = eval(str(var_j))
list_b.append(var_j)
if "/" in str(var_i):
    var_i = eval(str(var_i))
list_b.append(var_i)
if "/" in str(var_h):
    var_h = eval(str(var_h))
list_b.append(var_h)
if "/" in str(var_g):
    var_g = eval(str(var_g))
list_b.append(var_g)
if "/" in str(var_f):
    var_f = eval(str(var_f))
list_b.append(var_f)
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_r = 1
var_s = list_c[var_r-1]
print(var_s)
Category: Geometry

Question (EN): Minyeong has drawn the largest circle that can be drawn inside a square with an area of 400 square centimeters (cm2). If pi is 3.1, how many square centimeters (cm2) is the area of the circle Minyeong drew?
Question (KO): 민영이는 넓이가 400제곱센티미터인 정사각형 안에 그릴 수 있는 가장 큰 원을 그렸습니다. 원주율이 3.1일 때 민영이가 그린 원의 넓이는 몇 제곱센티미터입니까?

Answer: 310

Solution (Python):
var_a = 3.1
var_b = 400
var_c = 0.5
var_d = var_b ** var_c
var_e = 2
var_f = var_d / var_e
var_g = 2
var_h = var_f ** var_g
var_i = var_a * var_h
print(int(var_i))
Category: Geometry

Question (EN): Make a rectangle out of a wire that is 52 centimeters (cm) long. What is the maximum area of a rectangle that can be made?
Question (KO): 52센티미터(㎝)의 철사로 사각형을 만듭니다. 만들 수 있는 사각형의 최대 넓이는 얼마입니까?

Answer: 169

Solution (Python):
var_a = 52
var_b = 4
var_c = var_a / var_b
var_d = 2
var_e = var_c ** var_d
print(int(var_e))
Category: Comparison

Question (EN): In Seokjin's classroom, the number of desks in each row, both horizontally and vertically, is placed in a square shape. Seokjin's seat is 3rd from the front, 5th from the back, 4th from the right, and 2nd from the left. How many desks are there in Seokjin's classroom?
Question (KO): 석진이네 교실에는 가로, 세로 각 줄의 책상 수가 같게 사각형 모양으로 놓여 있습니다. 석진이의 자리는 앞에서 3번째, 뒤에서 5번째, 오른쪽에서 4번째, 왼쪽에서 2번째에 있습니다. 석진이네 교실의 책상은 모두 몇 개입니까?

Answer: 35

Solution (Python):
var_a = 3
var_b = 5
var_c = var_a + var_b
var_d = 1
var_e = var_c - var_d
var_f = 4
var_g = 2
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))
Category: Correspondence

Question (EN): The multiplication of the five-digit number ABCDE and 3 is 111111. Find the sum of A, B, C, D, and E.
Question (KO): 다섯 자리 수 ABCDE와 3의 곱은 111111입니다. A, B, C, D, E의 합을 구하시오.

Answer: 20

Solution (Python):
var_a = 111111
var_b = 3
var_c = var_a / var_b
list_a = []
var_c = int(var_c)
while var_c//10 > 0:
    list_a.append(var_c%10)
    var_c = var_c//10
list_a.append(var_c%10)
list_a = list_a[::-1]
list_a = [float(i) for i in list_a]
var_d = sum(list_a)
print(int(var_d))
Category: Arithmetic calculation

Question (EN): Which of the five-digit numbers is the greatest common multiple of 9, 6, and 2?
Question (KO): 다섯 자리 수 중 9, 6, 2의 공배수 중 가장 큰 수는?

Answer: 99990

Solution (Python):
var_a = 10000
var_b = 99999
var_c = 1
list_a = [i for i in range(var_a, var_b + 1, var_c)]
var_d = 9
list_b = []
var_d = int(var_d)
for i in list_a:
    i = int(i)
    if i % var_d == 0:
        list_b.append(i)
var_e = 6
list_c = []
var_e = int(var_e)
for i in list_b:
    i = int(i)
    if i % var_e == 0:
        list_c.append(i)
var_f = 2
list_d = []
var_f = int(var_f)
for i in list_c:
    i = int(i)
    if i % var_f == 0:
        list_d.append(i)
var_g = 1
list_e=list_d.copy()
list_e.sort()
var_h = list_e[-var_g]
print(int(var_h))
Category: Comparison

Question (EN): Four children (a), (b), (c), and (d) are competing in a running race. (c) is faster than (b) and (b) is slower than (d). If (d) is slower than (a) and (c) is slower than (d), which child is the slowest?
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 = '(a)'
var_f = '(d)'
var_g = '>'
var_h = '(c)'
var_i = '(d)'
var_j = '<'
var_k = '(d)'
var_l = '(b)'
var_m = '>'
var_n = '(b)'
var_o = '(c)'
var_p = '<'
list_b= []
if "/" in str(var_p):
    var_p = eval(str(var_p))
list_b.append(var_p)
if "/" in str(var_o):
    var_o = eval(str(var_o))
list_b.append(var_o)
if "/" in str(var_n):
    var_n = eval(str(var_n))
list_b.append(var_n)
if "/" in str(var_m):
    var_m = eval(str(var_m))
list_b.append(var_m)
if "/" in str(var_l):
    var_l = eval(str(var_l))
list_b.append(var_l)
if "/" in str(var_k):
    var_k = eval(str(var_k))
list_b.append(var_k)
if "/" in str(var_j):
    var_j = eval(str(var_j))
list_b.append(var_j)
if "/" in str(var_i):
    var_i = eval(str(var_i))
list_b.append(var_i)
if "/" in str(var_h):
    var_h = eval(str(var_h))
list_b.append(var_h)
if "/" in str(var_g):
    var_g = eval(str(var_g))
list_b.append(var_g)
if "/" in str(var_f):
    var_f = eval(str(var_f))
list_b.append(var_f)
if "/" in str(var_e):
    var_e = eval(str(var_e))
list_b.append(var_e)
list_b.reverse()
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_q = len(list_c)
var_r = list_c[var_q-1]
print(var_r)
Category: Arithmetic calculation

Question (EN): Students playing basketball are four times as much as students jumping rope. If the number of students jumping rope is 6, how many students are playing basketball?
Question (KO): 줄넘기를 하는 학생의 4배 만큼 농구를 하고 있습니다. 줄넘기를 하는 학생 수가 6명이라면 농구를 하는 학생 수는 몇 명입니까?

Answer: 24

Solution (Python):
var_a = 6
var_b = 4
var_c = var_a * var_b
print(int(var_c))
Category: Arithmetic calculation

Question (EN): You want to plant trees at intervals of 3.1 meters (m) in a garden with a width of 27.9 meters (m). Find how many trees you can plant. However, the thickness of the wood is not considered.
Question (KO): 너비가 27.9미터(m)인 텃밭에 3.1미터(m) 간격으로 나무를 심으려고 합니다. 나무를 몇 그루 심을 수 있는 지 구하시오. 단, 나무의 두께는 생각하지 않습니다.

Answer: 9

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

Question (EN): When you multiply a number by 4, you get 166.08. What is the value of a number divided by 4?
Question (KO): 어떤 수에 4를 곱하였더니 166.08이 되었습니다. 어떤 수를 4로 나눈 값이 얼마인지 구하시오.

Answer: 10.38

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

Question (EN): Hoseok added a number to 56 and got 110. Find the number.
Question (KO): 호석이는 56에 어떤 수를 더해 110을 얻었습니다. 어떤 수를 구하시오.

Answer: 54

Solution (Python):
var_a = 110
var_b = 56
var_c = var_a - var_b
print(int(var_c))
Category: Correspondence

Question (EN): 63+68A=748. How much is single-digit number A?
Question (KO): 63+68A=748입니다. A는 얼마인가요?

Answer: 5

Solution (Python):
var_a = '63+68A=748'
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): When there are three numbers: 0.8, 1/2, and 9, what would be the smallest one among the numbers that are greater than 2?
Question (KO): 3개의 숫자 0.8, 1/2, 9가 있습니다. 2보다 큰 수 중 가장 작은 수는 얼마인가요?

Answer: 9

Solution (Python):
var_a = 0.8
var_b = 0.5
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 = 2
list_b = []
for i in list_a:
    if i > var_d:
        list_b.append(i)
var_e = 1
list_c=list_b.copy()
list_c.sort()
var_f = list_c[var_e-1]
print(int(var_f))
Category: Comparison

Question (EN): Yoongi got 4, Yuna 5, and Jungkook got the quotient of 6 divided by 3. Who got the smallest number?
Question (KO): 윤기는 4, 유나는 5, 정국이는 6에서 3을 나눈 몫을 모았습니다. 누가 가장 작은 수를 모았습니까?

Answer: Jungkook

Solution (Python):
var_a = 'Yoongi'
var_b = 'Yuna'
var_c = 'Jungkook'
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 = 5
var_f = 6
var_g = 3
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)
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)