philschmid/DMath huggingface dataset:
Category: Arithmetic calculation

Question (EN): The quotient of this number divided by 105 is 14 and the remainder is 84. What is the value of dividing this number by 6, and then dividing the quotient by 7 again?
Question (KO): 어떤 수를 105로 나눈 몫이 14이고 나머지가 84이다. 어떤 수를 6으로 나누고 나온 몫을 다시 7로 나눈 몫이 얼마인지 구하시오.

Answer: 33

Solution (Python):
var_a = 105
var_b = 14
var_c = var_a * var_b
var_d = 84
var_e = var_c - var_d
var_f = 6
var_g = 7
var_h = var_f * var_g
var_i = var_e / var_h
print(int(var_i))
Category: Correspondence

Question (EN): There are cookies that are packed in 3 pieces. Hyunwoo gave 3 of these 226 packed cookies to his friend. Find how many pieces of cookies Hyunwoo has.
Question (KO): 3개씩 포장되어있는 과자가 있다. 현우는 이 포장된 과자 226개 중 3개를 친구에게 주었습니다. 현우가 가진 과자는 낱개로 모두 몇 개인지 구하시오.

Answer: 669

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

Question (EN): Woosik tries to double the number of jump ropes every day. If you jump rope 18 times on day 1, how many times will you jump rope on day 4?
Question (KO): 우식이는 줄넘기의 횟수를 매일 2배씩 늘려가려 합니다. 첫째날에 줄넘기를 18회 넘었다면 넷째날에는 모두 몇 회를 넘겠습니까?

Answer: 144

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

Question (EN): Which number is the second smallest among 5, 8, 9, and 7?
Question (KO): 5와 8과 9와 7 중 2번째로 작은 숫자는 무엇인가요?

Answer: 7

Solution (Python):
var_a = 5
var_b = 8
var_c = 9
var_d = 7
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=list_a.copy()
list_b.sort()
var_f = list_b[var_e-1]
print(int(var_f))
Category: Possibility

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

Answer: 370

Solution (Python):
var_a = 1
var_b = 55
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: Correspondence

Question (EN): Moving a decimal point two places to the left equals the original decimal minus 1.485. Find the original decimal number.
Question (KO): 어떤 소수의 소수점을 왼쪽으로 두 칸 옮기면 원래 소수에서 1.485를 뺀 값이 됩니다. 원래의 소수를 구하시오.

Answer: 1.5

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

Question (EN): Seonju ran 2+2/3 kilometers (km) every day. How many kilometers (km) did Seonju run for 9 days?
Question (KO): 선주는 매일 2+2/3킬로미터(㎞)씩 달렸습니다. 선주가 9일 동안 달린 거리는 모두 킬로미터(㎞)일까요?

Answer: 24

Solution (Python):
var_a = 2
var_b = 0.6666666666666666
var_c = var_a + var_b
var_d = 9
var_e = var_c * var_d
print(int(var_e))
Category: Possibility

Question (EN): How ways are there to choose and buy two fruits out of peaches, apples, pears, melons, and persimmons?
Question (KO): 복숭아, 사과, 배, 참외, 감 중에서 2가지의 과일을 골라서 사는 경우는 모두 몇 가지입니까?

Answer: 10

Solution (Python):
var_a = 5
var_b = 2
var_c = 1
var_a = int(var_a)
var_b = int(var_b)
for i, elem in enumerate(range(var_b)):
    var_c = var_c * (var_a-i)
for i, elem in enumerate(range(var_b)):
    var_c = var_c / (i+1)
print(int(var_c))
Category: Arithmetic calculation

Question (EN): It takes Jun-seok 4 hours to translate a chapter of an English book and it takes Yoon-yeol 12 hours. If the two of them work together, how many hours will it take to translate one chapter?
Question (KO): 영어 서적 1장을 번역하는데 준석이는 4시간이 걸리고 윤열이는 12시간이 걸린다. 둘이 번역을 함께한다면 1장을 번역하는데 몇시간이 걸리는지 구하시오.

Answer: 3

Solution (Python):
var_a = 1
var_b = 1
var_c = 4
var_d = var_b / var_c
var_e = 1
var_f = 12
var_g = var_e / var_f
var_h = var_d + var_g
var_i = var_a / var_h
print(int(var_i))
Category: Arithmetic calculation

Question (EN): What is the difference between the sum of numbers whose remainder is 1 and the sum of numbers whose remainder is 0 when divided by 2 from 1 to 100?
Question (KO): 1부터 100까지의 자연수 중 2로 나누었을 때 나머지가 1인 것들의 합과 0인 것들의 합의 차를 구하시오.

Answer: 50

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

Question (EN): There are a total of 86 chicks and chickens in the coop and 30 chicks. If hens lay 3 eggs per day, how many eggs can you get from this henhouse in 30 days?
Question (KO): 닭장 안에 병아리와 닭이 모두 합쳐 86마리가 있고 병아리는 30마리이다. 닭들이 하루에 3개의 알을 낳는다면 이 닭장에서 30일동안 얻을 수 있는 달걀의 개수를 구하시오.

Answer: 5040

Solution (Python):
var_a = 86
var_b = 30
var_c = var_a - var_b
var_d = 3
var_e = var_c * var_d
var_f = 30
var_g = var_e * var_f
print(int(var_g))
Category: Geometry

Question (EN): Find the surface area of a cuboid whose width is 3 centimeters (cm), length is 4 centimeters (cm), and height is 5 centimeters (cm).
Question (KO): 가로가 3센티미터(㎝) , 세로가 4 센티미터(㎝) , 높이가 5센티미터(㎝) 인 직육면체의 겉넓이를 구하시오.

Answer: 94

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

Question (EN): You have a square piece of paper with a side of 30 centimeters (cm). How many circles that has a radius of 3 centimeters (cm) can you make?
Question (KO): 한 변의 길이가 30센티미터(㎝)인 정사각형 종이가 있습니다. 반지름이 3센티미터(㎝)인 원을 최대 몇 개 만들 수 있습니까?

Answer: 25

Solution (Python):
var_a = 30
var_b = 3
var_c = 2
var_d = var_b * var_c
var_e = var_a // var_d
var_f = 2
var_g = var_e ** var_f
print(int(var_g))
Category: Comparison

Question (EN): 20 students are waiting for the bus. Jungkook came later than Yoongi, and there are 5 students between Yoongi and Jungkook. There are 6 students standing behind Jungkook. How many students are standing in front of Yoongi?
Question (KO): 20명의 학생들이 버스를 기다리고 있습니다. 정국이는 윤기보다 늦게 왔고, 윤기와 정국이 사이에는 5명의 학생이 있습니다. 정국의 뒤에는 6명의 학생들이 서 있습니다. 윤기의 앞에 서 있는 학생은 몇 명입니까?

Answer: 7

Solution (Python):
var_a = 20
var_b = 6
var_c = var_a - var_b
var_d = 1
var_e = var_c - var_d
var_f = 5
var_g = var_e - var_f
var_h = 1
var_i = var_g - var_h
print(int(var_i))
Category: Arithmetic calculation

Question (EN): There are 27, 103, 78, 35, and 97. What is the difference between the largest and the smallest of five numbers?
Question (KO): 27, 103, 78, 35, 97이 있습니다. 5개의 수 중 가장 큰 수와 작은 수의 차는 얼마입니까?

Answer: 76

Solution (Python):
var_a = 27
var_b = 103
var_c = 78
var_d = 35
var_e = 97
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 = 1
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: Geometry

Question (EN): Find the answer to how many vertices there are in a three-dimensional figure with two parallel sides congruent polygons and six rectangular sides.
Question (KO): 서로 평행한 두 면이 합동인 다각형이고 옆면이 직사각형 6개로 이루어진 입체도형의 꼭짓점은 몇 개인지 답을 구해보세요.

Answer: 12

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

Question (EN): Yoo-jeong borrowed some of the 17 notebooks from Min-young, and Min-young had 8 notebooks left. How many notebooks did Yoo-jeong borrow?
Question (KO): 유정이가 민영이에게 공책 17권 중 몇 권을 빌려갔더니 민영이에게 공책 8권이 남았습니다. 유정이가 빌려간 공책은 몇 권일까요?

Answer: 9

Solution (Python):
var_a = 17
var_b = 8
var_c = var_a - var_b
print(int(var_c))
Category: Correspondence

Question (EN): Subtracting 29 from any number and dividing it by 13 gives you 15. Find any number.
Question (KO): 어떤 수에서 29를 빼고 다시 13으로 나누면 15가 됩니다. 어떤 수를 구하시오.

Answer: 224

Solution (Python):
var_a = 15
var_b = 13
var_c = var_a * var_b
var_d = 29
var_e = var_c + var_d
print(int(var_e))
Category: Arithmetic calculation

Question (EN): It is said that the price is 17.25 won per 1 gram (g) of a certain mineral. When one 1000 gram (g) weight and one 10 gram (g) weight were placed on a balance, and a lump of the mineral was placed on the other side, it was level. How much is a mineral worth?
Question (KO): 어떤 광물 1그램(g) 당 17.25원의 가격이라고 합니다. 양팔 저울에 1000그램(g)짜리 분동 1개와 10그램(g)짜리 분동 1개를 올리고 반대 편에 광물 덩어리를 올렸더니 수평이 맞았다. 광물의 가치는 얼마입니까?

Answer: 17422.5

Solution (Python):
var_a = 17.25
var_b = 1000
var_c = var_a * var_b
var_d = 17.25
var_e = 10
var_f = var_d * var_e
var_g = var_c + var_f
print('{:.2f}'.format(round(var_g+1e-10,2)))
Category: Geometry

Question (EN): A rectangle has a perimeter of 30 centimeters (cm) and a width of 10 centimeters (cm). How long is the length of this rectangle?
Question (KO): 어떤 직사각형의 둘레가 30센티미터(㎝)이고 가로는 10센티미터(㎝)입니다. 이 직사각형의 세로의 길이는 얼마입니까?

Answer: 5

Solution (Python):
var_a = 30
var_b = 2
var_c = var_a / var_b
var_d = 10
var_e = var_c - var_d
print(int(var_e))
Category: Geometry

Question (EN): Hyeonsu was walking in the shape of a circle with a radius of 50 meters (m) in the playground. He takes a walk and tries to mark every 7.85 meters (m) with an X. If the pi is calculated as 3.14, how many X marks will there be when Hyeonsu makes a turn?
Question (KO): 현수는 운동장에서 반지름이 50미터(m)인 원 모양으로 산책을 하고 있었습니다. 산책을 하면서 7.85미터(m)마다 엑스 표시를 해두려고 합니다. 원주율을 3.14로 계산한다면, 현수가 한 바퀴를 돌았을 때 몇 개의 엑스 표시가 있겠습니까?

Answer: 40

Solution (Python):
var_a = 50
var_b = 2
var_c = var_a * var_b
var_d = 3.14
var_e = var_c * var_d
var_f = 7.85
var_g = var_e // var_f
print(int(var_g))
Category: Geometry

Question (EN): You have a trapezoid with a lower side of 9 centimeters (cm) and an upper side of 5 centimeters (cm). If the area is 56 square centimeters (cm2), how many centimeters (cm) is the height of this trapezoid?
Question (KO): 아랫변이 9센티미터(㎝)이고 윗변이 5센티미터(㎝)인 사다리꼴이 있습니다. 넓이를 구했더니 56제곱센티미터(㎠)이라면, 이 사다리꼴의 높이는 몇 센티미터(㎝)일까요?

Answer: 8

Solution (Python):
var_a = 56
var_b = 2
var_c = var_a * var_b
var_d = 5
var_e = 9
var_f = var_d + var_e
var_g = var_c / var_f
print(int(var_g))
Category: Arithmetic calculation

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

Answer: 0.92

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

Question (EN): Among the five numbers 9/10, 1.8, 2, 1, 11/5 , write the number greater than 1 and less than 2 including the decimal point.
Question (KO): 9/10, 1.8, 2, 1, 11/5 5개의 수 중에서 1보다 크고 2보다 작은 수를 소수점을 포함하여 답을 쓰시오.

Answer: 1.8

Solution (Python):
var_a = 0.9
var_b = 1.8
var_c = 2
var_d = 1
var_e = 2.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 = 1
list_b = []
for i in list_a:
    if i > var_f:
        list_b.append(i)
var_g = 2
list_c = []
for i in list_b:
    if i < var_g:
        list_c.append(i)
var_h = 1
var_i = list_c[var_h-1]
print('{:.2f}'.format(round(var_i+1e-10,2)))
Category: Arithmetic calculation

Question (EN): How many baskets are needed to divide 44 ping pong balls into 4 baskets?
Question (KO): 44개의 탁구공을 4개로 바구니에 나누어 담을 때 총 몇 개의 바구니가 필요한가?

Answer: 11

Solution (Python):
var_a = 44
var_b = 4
var_c = var_a / var_b
print(int(var_c))
Category: Geometry

Question (EN): If the radius of the large marble is 6 centimeters (cm) and the radius of the small marble is 3 centimeters (cm), how many times the surface area of the large marble is the surface area of the small marble?
Question (KO): 큰 구슬의 반지름은 6센티미터(㎝)이고, 작은 구슬의 반지름은 3센티미터(㎝)일 때, 큰 구슬의 겉넓이는 작은 구슬의 겉넓이의 몇 배인지 구하시오.

Answer: 4

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

Question (EN): There are 28 identical pianos in the music room. Each piano has the same number of keys. When you press the 14th key from the front and the 20th key from the back of a certain piano, find the number of keys on all the pianos in this music room.
Question (KO): 음악실에 똑같은 피아노가 28대 있습니다. 각 피아노마다 가진 건반의 수는 같습니다. 어느 피아노에서 앞에서 14번째, 뒤에서 20번째 건반을 눌렀을 때, 이 음악실 안에 있는 피아노들의 건반 수를 모두 구하시오.

Answer: 924

Solution (Python):
var_a = 14
var_b = 20
var_c = var_a + var_b
var_d = 1
var_e = var_c - var_d
var_f = 28
var_g = var_e * var_f
print(int(var_g))
Category: Geometry

Question (EN): There is a rectangular cuboid-shaped bowl measuring 16 centimeters (cm) wide, 14 centimeters (cm) long, and 9 centimeters (cm) high containing water 4 centimeters (cm) high. When a stone was placed in this bowl, the water level rose to 9 centimeters (cm). What is the volume of the stone in cubic centimeters (cm3)?
Question (KO): 가로 16센티미터(㎝), 세로 14센티미터(㎝), 높이 9센티미터(㎝)인 직육면체 모양의 그릇에 물이 4센티미터(㎝) 높이만큼 들어 있었습니다. 이 그릇에 돌을 넣었더니 물의 높이가 9센티미터(㎝)가 되었습니다. 돌의 부피는 몇 세제곱센티미터(㎤)입니까?

Answer: 1120

Solution (Python):
var_a = 16
var_b = 14
var_c = var_a * var_b
var_d = 9
var_e = 4
var_f = var_d - var_e
var_g = var_c * var_f
print(int(var_g))
Category: Comparison

Question (EN): There are three numbers 0.8, 1/2, and 0.9. How many numbers are greater than or equal to 2?
Question (KO): 3개의 숫자 0.8, 1/2, 0.9가 있습니다. 2보다 크거나 같은 수는 몇 개입니까?

Answer: 0

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 = 2
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): The radius of the smaller sphere is 1/4 of the radius of the larger sphere. Find how many times bigger the volume of the larger sphere is compared to the volume of the smaller sphere.
Question (KO): 작은 구의 반지름은 큰 구의 반지름의 1/4입니다. 큰 구의 부피는 작은 구의 부피의 몇 배인지 구하세요.

Answer: 64

Solution (Python):
var_a = 1
var_b = 0.25
var_c = 3
var_d = var_b ** var_c
var_e = var_a / var_d
print(int(var_e))
Category: Comparison

Question (EN): There are 28 identical bookshelves in the library. Each bookshelf has 6 floors, and the number of books on each floor is the same. An English book is placed 9th from the left and 11th from the right on one floor of a bookshelf. How many books are on the shelves in the library?
Question (KO): 도서관에 똑같은 책장이 28개 있습니다. 각 책장은 6층이고, 각 층마다 꽂혀 있는 책의 수는 같습니다. 영어책은 어느 책장의 한 층의 왼쪽에서 9번째, 오른쪽에서 11번째에 꽂혀 있습니다. 도서관의 책장에 꽂혀 있는 책은 모두 몇 권입니까?

Answer: 3192

Solution (Python):
var_a = 9
var_b = 11
var_c = var_a + var_b
var_d = 1
var_e = var_c - var_d
var_f = 6
var_g = var_e * var_f
var_h = 28
var_i = var_g * var_h
print(int(var_i))
Category: Geometry

Question (EN): There is a cuboid-shaped rice container full of rice with a height of 5 meters (m) 20 centimeters (cm) and a base with side lengths of 6 meters (m) 40 centimeters (cm) and 9 meters (m) respectively. You want to divide the rice into several rice bins of 1 cubic meter (m3) in volume. Find how many boxes of rice you need at least.
Question (KO): 높이가 5미터(m) 20센티미터(㎝)이고 밑면이 각각 6미터(m) 40센티미터(㎝), 9미터(m)인 쌀이 가득 들어있는 직육면체 모양의 쌀통이 있습니다. 쌀을 부피가 1세제곱미터(㎥)인 쌀통 여러 개에 모두 나누어 담으려고 합니다. 쌀통은 적어도 몇 개 필요한지 구해보시오.

Answer: 300

Solution (Python):
var_a = 6
var_b = 40
var_c = 100
var_d = var_b / var_c
var_e = var_a + var_d
var_f = 9
var_g = var_e * var_f
var_h = 5
var_i = 20
var_j = 100
var_k = var_i / var_j
var_l = var_h + var_k
var_m = var_g * var_l
var_n = 1
var_o = var_m / var_n
var_p = 1
var_q=int(((var_o+9*10**(var_p-2))//(10**(var_p-1)))*10**(var_p-1))

print(int(var_q))
Category: Comparison

Question (EN): Taehyung, Namjoon, and Jimin bought apples at the fruit shop. If Jimin bought more apples than Taehyung and Taehyung bought more apples than Namjoon, who bought the most apples?
Question (KO): 과일가게에서 태형, 남준, 지민이가 사과를 샀습니다. 지민이는 태형이보다 사과를 많이 샀고, 태형이는 남준이보다 사과를 많이 샀다면, 사과를 가장 많이 산 학생은 누구인가요?

Answer: Jimin

Solution (Python):
var_a = 'Taehyung'
var_b = 'Namjoon'
var_c = 'Jimin'
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 = 'Taehyung'
var_e = 'Namjoon'
var_f = '>'
var_g = 'Jimin'
var_h = 'Taehyung'
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: Correspondence

Question (EN): Taking B2 from 8A made it 45. What is A+B?
Question (KO): 8A-B2=45라고 합니다. A, B가 서로 다른 두 수 일 때, A+B는 무엇인가요?

Answer: 11

Solution (Python):
var_a = '8A-B2=45'
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 = '8A-B2=45'
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
print(int(var_g))
Category: Correspondence

Question (EN): Adding 468 to a certain number gives 954. What is the result when subtracting 3 from this number?
Question (KO): 어떤 수에 468을 더하면 954가 나온다. 어떤 수에서 3을 빼면 얼마인지 구하시오.

Answer: 483

Solution (Python):
var_a = 954
var_b = 468
var_c = var_a - var_b
var_d = 3
var_e = var_c - var_d
print(int(var_e))