philschmid/DMath huggingface dataset:
Category: Geometry

Question (EN): Mihyang cut the colored paper into regular hexagons so that each side is 5 centimeters (cm) long. What is the perimeter of this regular hexagon in centimeters (cm)?
Question (KO): 미향이는 색종이를 한 변의 길이가 5센티미터(㎝)가 되도록 정육각형 모양으로 잘랐습니다. 이 정육각형의 둘레는 몇 센티미터(㎝)입니까?

Answer: 30

Solution (Python):
var_a = 5
var_b = 6
var_c = var_a * var_b
print(int(var_c))
Category: Geometry

Question (EN): There is a rhombus with an area of 24.48 square centimeters (cm2). If one diagonal of this rhombus is 8 centimeters (cm), find the difference between the length of this diagonal and the other diagonal.
Question (KO): 넓이가 24.48제곱센티미터(㎠)인 마름모가 있습니다. 이 마름모의 한 대각선이 8센티미터(㎝)일 때 이 대각선과 다른 대각선의 길이의 차를 구하시오.

Answer: 1.88

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

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

Answer: 0.8

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 = 3
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]
print('{:.2f}'.format(round(var_g+1e-10,2)))
Category: Comparison

Question (EN): Seokjin and Taehyung jumped ropes for two days yesterday and today. Seokjin did 15 more today than yesterday, and Taehyung did 12 fewer today than yesterday. If Seokjin and Taehyung jumped ropes 32 times and 58 times respectively yesterday, then find out who skipped more ropes today.
Question (KO): 석진이와 태형이는 어제와 오늘 이틀동안 줄넘기를 했습니다. 석진이는 어제보다 오늘 15개 많이 했고, 태형이는 어제보타 오늘 12번 더 적게 했습니다. 석진이와 태형이가 어제 한 줄넘기의 수가 각각 32번, 58번이라면, 오늘 줄넘기를 더 많이 넘은 사람은 누구인지 구하시오.

Answer: Seokjin

Solution (Python):
var_a = 'Seokjin'
var_b = 'Taehyung'
list_a= []
if "/" in str(var_b):
    var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
    var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_c = 32
var_d = 15
var_e = var_c + var_d
var_f = 58
var_g = 12
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: Arithmetic calculation

Question (EN): The box, which had 12 identical children's books inside, weighed 11.48 kilograms (kg). When 4 children's books were removed from the box, it weighed 8.12 kilograms (kg). What is the weight of the empty box in kilograms (kg)?
Question (KO): 똑같은 동화책 12권이 들어있는 상자의 무게를 재어 보니 11.48킬로그램(㎏)이었습니다. 이 상자에서 동화책 4권을 뺀 다음 다시 무게를 재었더니 8.12킬로그램(㎏) 이 되었습니다. 빈 상자의 무게는 몇 킬로그램(㎏)인지 구하시오.

Answer: 1.4

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

Question (EN): Find out how many three-digit prime numbers exist, which are less than 3.01 but greater than 3, and have 3 as its units digit, 0 and 6 as the 1st and 2nd decimal place, and 6 as the 3rd decimal place.
Question (KO): 일의 자리 숫자가 3 이고, 소수 첫째 자리 숫자와 소수 둘째 자리 숫자가 0, 소수 셋째 자리 숫자가 6 인 수보다 큰 수 중에서 3.01 보다 작은 소수 세 자리 수는 모두 몇 개입니까?

Answer: 3

Solution (Python):
var_a = 0
var_b = 9
var_c = 1
list_a = [i for i in range(var_a, var_b + 1, var_c)]
var_d = 6
list_b = []
for i in list_a:
    if i > var_d:
        list_b.append(i)
var_e = len(list_b)
print(int(var_e))
Category: Arithmetic calculation

Question (EN): If you write down the numbers 1 through 50 once on a piece of paper, find how many times you write 1.
Question (KO): 1부터 50까지 종이에 차례대로 한 번씩 쓸 때, 1은 몇 번 쓰게 되는지 구하시오.

Answer: 15

Solution (Python):
var_a = 1
var_b = 50
var_c = 1
list_a = [i for i in range(var_a, var_b + 1, var_c)]
var_d=""
for i in list_a:
    i = str(i)
    var_d = var_d + i
list_b = []
var_d = int(var_d)
while var_d//10 > 0:
    list_b.append(var_d%10)
    var_d = var_d//10
list_b.append(var_d%10)
list_b = list_b[::-1]
var_e = 1
var_f = 0
var_e = int(var_e)
for i in list_b:
    i = int(i)
    if i == var_e:
        var_f = var_f + 1
print(int(var_f))
Category: Possibility

Question (EN): Jungkook bought two boxes each containing three red balls. How many red balls does Jungkook have?
Question (KO): 정국이는 빨간 공 3개가 들어 있는 상자 2개를 샀습니다. 정국이가 가지고 있는 빨간 공의 개수는?

Answer: 6

Solution (Python):
var_a = 3
var_b = 2
var_c = var_a * var_b
print(int(var_c))
Category: Arithmetic calculation

Question (EN): You are trying to pack 24 tangerines and 18 apples in one box. If there are no remaining apples or tangerines and each box contains the same number, find the maximum number of boxes you can make.
Question (KO): 귤 24개와 사과 18개를 한 박스에 담아 포장하려한다. 남는 사과나 귤이 없고 박스마다 똑같은 개수로 담는다고 할 때, 최대 몇 박스를 만들 수 있는지 구하시오.

Answer: 6

Solution (Python):
var_a = 24
var_b = 18
var_c = math.gcd(int(var_b), int(var_a))
print(int(var_c))
Category: Geometry

Question (EN): Junyoung has a hoop with a diameter of 50 centimeters (cm). After rolling this hoop several times, it moved forward by 6 meters (m) and 28 centimeters (cm). If the pi is 3.14, how many times does the hoop need to be rolled?
Question (KO): 준영이는 지름이 50센티미터(㎝)인 굴렁쇠를 갖고 있습니다. 이 굴렁쇠를 몇 바퀴 굴렸더니 6미터(m) 28센티미터(㎝)만큼 앞으로 나아갔습니다. 원주율이 3.14라면, 굴렁쇠를 몇 바퀴 굴려야 합니까?

Answer: 4

Solution (Python):
var_a = 6
var_b = 100
var_c = var_a * var_b
var_d = 28
var_e = var_c + var_d
var_f = 50
var_g = 3.14
var_h = var_f * var_g
var_i = var_e / var_h
print(int(var_i))
Category: Arithmetic calculation

Question (EN): Aunt Yujeong gave three carrots to her nephew, Yoongi. Yoongi's older sister received 4, but she gave 2 to Yoongi again. How many carrots does Yoongi have?
Question (KO): 유정이 이모는 조카 윤기에게 당근을 3개 주었습니다. 윤기의 누나는 윤기에게 2개를 주었습니다. 윤기가 가진 당근은 몇 개입니까?

Answer: 5

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

Question (EN): Jimin is trying to subtract a number from 34. If the result of mistakenly dividing 96 by a number is 6, find the correct result.
Question (KO): 지민이는 34에 어떤 수를 빼려고 합니다. 실수로 96에 어떤 수를 나눴을 때의 결과가 6이라면 바르게 계산한 결과를 구하세요.

Answer: 18

Solution (Python):
var_a = 34
var_b = 96
var_c = 6
var_d = var_b / var_c
var_e = var_a - var_d
print(int(var_e))
Category: Possibility

Question (EN): Four non-overlapping numbers from 0 to 9 were drawn and made a four-digit number. What is the difference between the second largest and the second smallest possible cases?
Question (KO): 0부터 9까지의 숫자 중 겹치는 것 없이 네 개를 뽑고 이것으로 네 자리 수를 만들었습니다. 만들 수 있는 경우 중 두 번째로 큰 수와 두 번째로 작은 수의 차는 얼마입니까?

Answer: 8851

Solution (Python):
var_a = 0
var_b = 9
var_c = 1
list_a = [i for i in range(var_a, var_b + 1, var_c)]
var_d = 4
list_b = [str(i) for i in list_a]
list_b = list(itertools.permutations(list_b, var_d))
list_b = [''.join(num_list) for num_list in list_b]
list_b = [str_num for str_num in list_b if str_num[0] != '0']
list_b = [float(i) for i in list_b]
var_e = 2
list_c=list_b.copy()
list_c.sort()
var_f = list_c[-var_e]
var_g = 2
list_d=list_b.copy()
list_d.sort()
var_h = list_d[var_g-1]
var_i = var_f - var_h
print(int(var_i))
Category: Possibility

Question (EN): If there are 6 students in the auditorium, find the number of cases in which 1 class president, 1 moderator, 1 vice-president, and 1 assistant moderator are selected.
Question (KO): 6명의 학생이 강당에 있을 때, 반장 1명, 사회자 1명, 부반장 1명, 부사회자 1명을 뽑는 경우의 수를 구하시오.

Answer: 360

Solution (Python):
var_a = 6
var_b = 1
var_c = 1
var_d = var_b + var_c
var_e = 1
var_f = var_d + var_e
var_g = 1
var_h = var_f + var_g
var_i = 1
var_a = int(var_a)
var_h = int(var_h)
for i, elem in enumerate(range(var_h)):
    var_i = var_i * (var_a-i)
print(int(var_i))
Category: Comparison

Question (EN): How many of 0.9, 5/10, 1, 7/10, and 1.2 are greater than 0.8?
Question (KO): 0.9, 5/10, 1, 7/10, 1.2 중 0.8보다 큰 수는 몇 개입니까?

Answer: 3

Solution (Python):
var_a = 0.9
var_b = 0.5
var_c = 1
var_d = 0.7
var_e = 1.2
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 = 0.8
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: Comparison

Question (EN): There are numbers 0.8, 1/2, and 0.9. Find the greatest number among the given numbers less than or equal to 0.6.
Question (KO): 0.8, 1/2, 0.9의 숫자가 있다. 이 중 0.6보다 작거나 같은 숫자들 중 가장 크거나 같은 수를 구하시오.

Answer: 0.5

Solution (Python):
var_a = 0.8
var_b = 0.5
var_c = 0.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 = 0.6
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]
print('{:.2f}'.format(round(var_f+1e-10,2)))
Category: Possibility

Question (EN): You took three number jellies from the vending machine and they were numbered 0, 1, and 5. If you use two out of three jellies, how many two-digit numbers can you create?
Question (KO): 자판기에서 숫자 젤리 3개를 뽑았더니 0, 1, 5가 나왔습니다. 3개의 젤리 중 2개를 사용하여 만들 수 있는 두 자리 수는 모두 몇 개 입니까?

Answer: 4

Solution (Python):
var_a = 0
var_b = 1
var_c = 5
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 = [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): What is the surface area of a cuboid that is 8 centimeters (cm) wide, 5 centimeters (cm) long, and 10 centimeters (cm) height?
Question (KO): 가로 8센티미터(㎝), 세로 5센티미터(㎝), 높이 10센티미터(㎝)인 직육면체의 겉넓이는 얼마입니까?

Answer: 340

Solution (Python):
var_a = 8
var_b = 5
var_c = var_a * var_b
var_d = 8
var_e = 10
var_f = var_d * var_e
var_g = var_c + var_f
var_h = 5
var_i = 10
var_j = var_h * var_i
var_k = var_g + var_j
var_l = 2
var_m = var_k * var_l
print(int(var_m))
Category: Comparison

Question (EN): Find the sum of the numbers that are greater than or equal to 1.1 among the five numbers 1.4, 9/10, 1.2, 0.5, and 13/10.
Question (KO): 수 5개 1.4, 9/10, 1.2, 0.5, 13/10 중 1.1보다 크거나 같은 숫자를 구하고, 그 숫자들의 합을 구하면 얼마입니까?

Answer: 3.9

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)
list_b = [float(i) for i in list_b]
var_g = sum(list_b)
print('{:.2f}'.format(round(var_g+1e-10,2)))
Category: Geometry

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

Answer: 8

Solution (Python):
var_a = 10
var_b = 2
var_c = var_a ** var_b
var_d = 6
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: Arithmetic calculation

Question (EN): A truck travels 2.1 kilometers (km) in 1 minute at a constant speed, while a taxi covers 10.5 km in 4 minutes. Which vehicle is quicker, the taxi or truck, by how many times?
Question (KO): 일정한 빠르기로 1분에 2.1킬로미터(㎞)를 달리는 트럭과 4분에 10.5킬로미터(㎞)를 달리는 택시가 있습니다. 택시와 트럭 중 더 빠른 것은 몇 배나 더 빠른가?

Answer: 1.25

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

Question (EN): Subtracting 2 twice from a certain number results in 5. What is the certain number?
Question (KO): 어떤 수에서 2를 두번 빼면 5가 됩니다. 어떤 수는 얼마인지 구하시오.

Answer: 9

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

Question (EN): Seungmin picked up 4.56 kilograms (kg) of chestnuts and Hyein picked up 10 times as much as 462 grams (g). Who picked up more chestnuts, Seungmin or Hyein?
Question (KO): 승민이는 밤을 4.56킬로그램(㎏) 주웠고 혜인이는 462그램(g)의 10 배 만큼 주웠습니다. 승민이와 혜인이 중에서 누가 밤을 더 많이 주웠습니까?

Answer: Hyein

Solution (Python):
var_a = 'Seungmin'
var_b = 'Hyein'
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.56
var_d = 462
var_e = 10
var_f = var_d * var_e
var_g = 1000
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_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: Correspondence

Question (EN): While Yoongi was subtracting 57 from the four digit number, Yoongi mistakenly saw the 9 in the ones digit of the four digit number as 6. If Yoongi got 1819 from this, what is the correct calculation result?
Question (KO): 윤기는 네 자리 수에 57을 빼던 중, 윤기는 네 자리 수의 일의 자리 숫자 9를 6으로 잘못 봤습니다. 윤기가 구한 차가 1819라고 하면, 바르게 계산한 결과는 무엇인가요?

Answer: 1822

Solution (Python):
var_a = 1819
var_b = 57
var_c = var_a + var_b
var_d = 6
var_e = 9
var_f = var_d - var_e
var_g = var_c - var_f
var_h = 57
var_i = var_g - var_h
print(int(var_i))
Category: Geometry

Question (EN): Hosok bought a few centimeters (cm) of wire and cut a length equal to the circumference of an equilateral triangle with a side length of 19 centimeters (cm). If the wire left after cutting is 15 centimeters (cm), what is the length in centimeters (cm) of the wire that Hoseok bought?
Question (KO): 호석이는 철사를 몇 센티미터(㎝) 구입해서 한 변의 길이가 19센티미터(㎝)인 정삼각형의 둘레의 길이만큼을 잘라냈다. 잘라내고 남은 철사가 15센티미터(㎝)라면, 호석이가 구입한 철사의 길이는 몇 센티미터(㎝)인가?

Answer: 72

Solution (Python):
var_a = 19
var_b = 3
var_c = var_a * var_b
var_d = 15
var_e = var_c + var_d
print(int(var_e))
Category: Comparison

Question (EN): Heejin and Heechul are collecting books. Heechul has 2 more books than Heejin. Dongkyun has fewer books than Heejin. Which of the three has the most books?
Question (KO): 희진이와 희철이는 책을 모으고 있습니다. 희철이가 희진이보다 책을 2권 더 많이 가지고 있습니다. 동균이가 가진 책은 희진이가 가진 책의 수보다 적습니다. 세 명 중 가장 많은 책을 가진 사람은 누구입니까?

Answer: Heechul

Solution (Python):
var_a = 'Heejin'
var_b = 'Heechul'
var_c = 'Dongkyun'
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 = 'Heechul'
var_e = 'Heejin'
var_f = '>'
var_g = 'Dongkyun'
var_h = 'Heejin'
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 = 1
var_k = list_c[var_j-1]
print(var_k)
Category: Arithmetic calculation

Question (EN): Find how many grams (g) of water evaporated from 300 grams (g) of 4% sugar water to make 10% sugar water.
Question (KO): 4%의 설탕물 300그램(g)에서 몇 그램(g)의 물을 증발시키면 10%의 설탕물이 되는지 구하여라

Answer: 180

Solution (Python):
var_a = 300
var_b = 300
var_c = 4
var_d = 100
var_e = var_c / var_d
var_f = var_b * var_e
var_g = 100
var_h = 10
var_i = var_g / var_h
var_j = var_f * var_i
var_k = var_a - var_j
print(int(var_k))
Category: Geometry

Question (EN): If you double the length of each edge of a cube, how many times bigger does the cube's surface area become?
Question (KO): 정육면체의 각 모서리의 길이를 2배로 늘리면 정육면체의 겉넓이는 몇 배가 되는가?

Answer: 4

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

Question (EN): What is the smallest five-digit number that is a multiple of 9 and a multiple of 6 and a multiple of 2?
Question (KO): 9의 배수이면서 6의 배수이면서 2의 배수인 수 중 가장 작은 다섯 자리 수는 무엇입니까?

Answer: 10008

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-1]
print(int(var_h))
Category: Arithmetic calculation

Question (EN): You have 200 grams (g) of salt water with a concentration of 25%, and 60 grams (g) of salt are dissolved in another 300 grams (g) of salt water. What is the percent concentration of the salt water when these two salt water are mixed?
Question (KO): 진하기가 25 %인 소금물 200 그램(g)이 있고, 다른 소금물 300 그램(g)에는 소금이 60 그램(g) 녹아 있습니다. 이 두 소금물을 섞었을 때 소금물의 진하기는 몇 %입니까?

Answer: 22

Solution (Python):
var_a = 200
var_b = 25
var_c = 100
var_d = var_b / var_c
var_e = var_a * var_d
var_f = 60
var_g = var_e + var_f
var_h = 200
var_i = 300
var_j = var_h + var_i
var_k = var_g / var_j
var_l = 100
var_m = var_k * var_l
print(int(var_m))
Category: Arithmetic calculation

Question (EN): The subway is moving 1.6 kilometers (km) per minute. If the distance between the previous station and this station is 4.85 kilometers (km), and it took 3 minutes and 15 seconds to pass this station completely from the previous station, how long is the subway in meters (m)?
Question (KO): 지하철이 1분에 1.6킬로미터(㎞)씩 이동하고 있습니다. 전 역과 이번 역의 사이 거리가 4.85킬로미터(㎞)일 때 전 역에서 출발해 이번 역을 완전히 지나치는 데 3분 15초가 걸렸다면, 지하철의 길이는 몇 미터(m)일까요?

Answer: 350

Solution (Python):
var_a = 1.6
var_b = 3
var_c = 15
var_d = 60
var_e = var_c / var_d
var_f = var_b + var_e
var_g = var_a * var_f
var_h = 4.85
var_i = var_g - var_h
var_j = 1000
var_k = var_i * var_j
print(int(eval('{:.2f}'.format(round(var_k+1e-10,2)))))
Category: Arithmetic calculation

Question (EN): Minseok started reading a storybook and read 1/3 of it yesterday and 2/5 of it today. What is the total number of unread parts?
Question (KO): 민석이가 동화책을 읽기 시작하여 어제는 전체의 1/3을, 오늘은 전체의 2/5를 읽었습니다. 안 읽은 부분은 전체의 얼마인지 구하시오.

Answer: 0.27

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

Question (EN): Subtracting 27 from a number gives 46. What is the number multiplied by 46?
Question (KO): 어떤 수에서 27을 뺐더니 46이 되었습니다. 어떤 수에 46을 곱하면 얼마인지 구하시오.

Answer: 3358

Solution (Python):
var_a = 27
var_b = 46
var_c = var_a + var_b
var_d = 46
var_e = var_c * var_d
print(int(var_e))
Category: Correspondence

Question (EN): Subtracting 174 from a number and multiplying it by 19 yields 3439. What is a number?
Question (KO): 19배를 한 결과가 3439가 되기 위해서는 어떤 수에서 174를 빼야합니다. 어떤 수는 무엇입니까?

Answer: 355

Solution (Python):
var_a = 3439
var_b = 19
var_c = var_a / var_b
var_d = 174
var_e = var_c + var_d
print(int(var_e))
Category: Correspondence

Question (EN): There are different numbers A, B, C, and D. Given that A+A=6, BA=4, C+B=9, and D-C=7. Find out what D is.
Question (KO): 서로 다른 수 A, B, C, D가 있습니다. A+A=6, B-A=4, C+B=9, D-C=7입니다. D를 구하시오.

Answer: 9

Solution (Python):
var_a = 'A+A=6'
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] = 0
candidate_num = [i for i in range(51)]
candi = list(itertools.product(candidate_num, 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)):
        if term_list[i] == '':
            new_eq += str(term_list[i])+op_list[i]
        else:
            new_eq += str(int(term_list[i]))+op_list[i]
    new_eq += str(int(term_list[-1]))
    new_eq=new_eq.replace('=', '==')
    new_eq=new_eq.replace('>==', '>=')
    new_eq=new_eq.replace('<==', '<=')
    eval_result = False
    try:
        if '=' in new_eq and '>' not in new_eq and '<' not in new_eq:
            new_eq=new_eq.replace('==','=')
            new_eq=new_eq.replace('>','')
            new_eq=new_eq.replace('<','')
            new_eq=new_eq.split('=')
            for i in range(len(new_eq)-1):
                eval_result = math.isclose(eval(new_eq[i]), eval(new_eq[i+1]))
                if not eval_result:
                    break
        else:
            eval_result = eval(new_eq)
    except:
        eval_result = False
        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 = 4
var_e = var_c + var_d
var_f = 9
var_g = var_e - var_f
var_h = 7
var_i = var_g - var_h
var_j = -1
var_k = var_i * var_j
print(int(var_k))