philschmid/DMath huggingface dataset:
Category: Correspondence

Question (EN): There are four different numbers A, B, C, and D. Find A from the four-digit and three-digit subtraction equation AB82-9C9=493D.
Question (KO): 서로 다른 네 수 A, B, C, D가 있습니다. 네 자리 수와 세 자리 수의 뺄셈식 AB82-9C9=493D에서 A를 구하시오.

Answer: 5

Solution (Python):
var_a = 'AB82-9C9=493D'
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): Yoojung placed balls of various colors in a row on the desk. If she put the ball in an order of red, blue, yellow, purple, and white, 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: Comparison

Question (EN): There are 10 boxes of 50 purple marbles each weighing 3 grams (g). There are 9 boxes of 60 pink marbles each weighing 2.5 grams (g). Which color marble weighs more when the total marbles of each color were weighed?
Question (KO): 1개의 무게가 3그램(g)인 보라색 구슬을 50개씩 담은 상자가 10개 있습니다. 1개의 무게가 2.5그램(g)인 분홍색 구슬을 60개씩 담은 상자가 9개 있습니다. 색깔별 구슬 전체의 무게가 더 무거운 것은 무슨 색 구슬입니까?

Answer: purple

Solution (Python):
var_a = 'purple'
var_b = 'pink'
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 = 3
var_d = 50
var_e = 10
var_f = var_d * var_e
var_g = var_c * var_f
var_h = 2.5
var_i = 60
var_j = 9
var_k = var_i * var_j
var_l = var_h * var_k
list_b= []
if "/" in str(var_l):
    var_l = eval(str(var_l))
list_b.append(var_l)
if "/" in str(var_g):
    var_g = eval(str(var_g))
list_b.append(var_g)
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: Comparison

Question (EN): At the supermarket, Jimin, Jungkook, and Taehyung lined up one after another. When Jimin is the second one, what number is Taehyung?
Question (KO): 마트에서 지민, 정국, 태형이가 차례대로 줄을 섰습니다. 지민이가 2번째일 때, 태형이는 몇 번째 입니까?

Answer: 4

Solution (Python):
var_a = 2
var_b = 'Jimin'
var_c = 'Jungkook'
var_d = 'Taehyung'
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)
list_a.reverse()
var_e = 'Taehyung'
var_f = list_a.index(var_e)+1
var_g = 'Jimin'
var_h = list_a.index(var_g)+1
var_i = var_f - var_h
var_j = var_a + var_i
print(int(var_j))
Category: Arithmetic calculation

Question (EN): There are 8 candies in basket (A) and 17 candies in basket (B). Find how many more candies must be placed in basket (A) to make the number of candies in both baskets equal.
Question (KO): (가) 바구니에는 사탕이 8개, (나) 바구니에는 17개 있습니다. 두 바구니에 담긴 사탕의 개수를 같게 하려면 (가) 바구니에 몇 개의 사탕을 더 놓아야하는지 구하시오.

Answer: 9

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

Question (EN): 22 is the result from a certain number minus 48. What is 32 less than the number?
Question (KO): 22는 어떤 수에서 48을 뺀 수입니다. 어떤 수보다 32작은 숫자는 얼마인가요.

Answer: 38

Solution (Python):
var_a = 22
var_b = 48
var_c = var_a + var_b
var_d = 32
var_e = var_c - var_d
print(int(var_e))
Category: Comparison

Question (EN): Among 5, 8, 9, and 7, which is the largest number?
Question (KO): 5와 8과 9와 7 중 가장 큰 숫자는 무엇인가요?

Answer: 9

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 = 1
list_b=list_a.copy()
list_b.sort()
var_f = list_b[-var_e]
print(int(var_f))
Category: Possibility

Question (EN): Yoongi's school is preparing for a school performance. How many possible cases are there when there are 8 classes to set the order of the school play?
Question (KO): 윤기네 학교에서 학예회를 준비하고 있습니다. 8개의 반이 학예회 순서를 정해야 할때 가능한 경우는 모두 몇 가지입니까?

Answer: 40320

Solution (Python):
var_a = 8
var_b = 8
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)
print(int(var_c))
Category: Arithmetic calculation

Question (EN): At a large market, in the morning, I sold 3/5 of the snacks that were displayed at dawn. In the afternoon, 180 snacks  in total were sold, including those left from the morning and newly displayed snacks. If the number of snacks sold in the morning and the snack sold in the afternoon was the same, how many snacks were displayed at dawn?
Question (KO): 대형 마트에서 새벽에 진열한 과자를 오전에 3/5만큼 팔았습니다. 오후에는 오전에 팔고 남은 과자와 새로 진열한 과자를 합한 180개의 과자를 모두 팔았습니다. 오전에 판 과자와 오후에 판 과자의 수가 같았다면, 새벽에 진열한 과자는 몇 개입니까?

Answer: 300

Solution (Python):
var_a = 180
var_b = 0.6
var_c = var_a / var_b
print(int(var_c))
Category: Correspondence

Question (EN): When 170 is divided by a number, the remainder is 8. When 120 is divided by the number, the remainder is 12. When 268 is added by 2, it is divisible by the number. Among the numbers that are possible, find the largest value.
Question (KO): 170을 어떤 수로 나누면 나머지가 8이고 120을 어떤 수로 나누면 나머지가 12이며 268에 2를 더하면 어떤 수로 나누어 떨어진다. 가능한 어떤 수 중 가장 큰 값을 구하시오.

Answer: 54

Solution (Python):
var_a = 170
var_b = 8
var_c = var_a - var_b
var_d = 268
var_e = 2
var_f = var_d + var_e
var_g = math.gcd(int(var_f), int(var_c))
var_h = 120
var_i = 12
var_j = var_h - var_i
var_k = math.gcd(int(var_j), int(var_g))
print(int(var_k))
Category: Geometry

Question (EN): You are trying to make a cube by cutting a cuboid. If the width of the cube is 12 centimeters (cm), the length is 16 centimeters (cm), and the height is 14 centimeters (cm), what is the value of the surface area of the largest cube?
Question (KO): 직육면체를 잘라서 정육면체를 만들려고 한다. 직육면체의 가로는 12센티미터(㎝), 세로는 16센티미터(㎝), 높이는 14센티미터(㎝) 일 때, 가장 큰 정육면체의 겉넓이의 값은?

Answer: 864

Solution (Python):
var_a = 12
var_b = 16
var_c = 14
list_a= []
if "/" in str(var_c):
    var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
    var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
    var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_d = 1
list_b=list_a.copy()
list_b.sort()
var_e = list_b[var_d-1]
var_f = 2
var_g = var_e ** var_f
var_h = 6
var_i = var_g * var_h
print(int(var_i))
Category: Arithmetic calculation

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

Answer: 25

Solution (Python):
var_a = 10
var_b = 11
var_c = 12
var_d = 13
list_a= []
if "/" in str(var_d):
    var_d = eval(str(var_d))
list_a.append(var_d)
if "/" in str(var_c):
    var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
    var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
    var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_e = 1
list_b=list_a.copy()
list_b.sort()
var_f = list_b[-var_e]
var_g = 2
list_c=list_a.copy()
list_c.sort()
var_h = list_c[-var_g]
var_i = var_f + var_h
print(int(var_i))
Category: Arithmetic calculation

Question (EN): A flower shop sold 3/5 of the flowers brought at dawn in the morning. In the afternoon, they sold all 180 flowers, including the remaining flowers after the morning and the newly brought flowers. If the number of flowers sold in the morning and the number of flowers sold in the afternoon were the same, how many flowers did they bring at dawn?
Question (KO): 어느 꽃집에서 새벽에 들여온 꽃을 오전에 3/5만큼 팔았습니다. 오후에는 오전에 팔고 남은 꽃과 새로 들여온 꽃을 합한 180 송이를 모두 팔았습니다. 오전에 판 꽃의 수와 오후에 판 꽃의 수가 같았다면, 새벽에 들여온 꽃은 몇 송이입니까?

Answer: 300

Solution (Python):
var_a = 180
var_b = 0.6
var_c = var_a / var_b
print(int(var_c))
Category: Geometry

Question (EN): What is the sum of all the sides of a regular pentagon with a side of 15 centimeters (cm) in centimeters (cm)?
Question (KO): 한 변이 15센티미터(㎝)인 정오각형의 모든 변의 길이의 합은 몇 센티미터(㎝)입니까?

Answer: 75

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

Question (EN): When Geongrin measured a span of his hand, it was 12 centimeters (cm) long. Gyeongrin measured the length of the long side of the notebook, and it was twice as long as the span. Approximately, how long is the long side of the notebook in centimeters (cm)?
Question (KO): 경린이의 한 뼘의 길이는 약 12센티미터(㎝)입니다. 경린이가 공책의 긴 쪽의 길이를 재었더니 뼘으로 2번이었습니다. 공책의 긴 쪽의 길이는 약 몇 센티미터(㎝)입니까?

Answer: 24

Solution (Python):
var_a = 12
var_b = 2
var_c = var_a * var_b
print(int(var_c))
Category: Geometry

Question (EN): A trapezoid has an area of 100.62 square centimeters (cm2), a height of 5.2 centimeters (cm), and the top side is 3.4 centimeters (cm) longer than the bottom side. How many centimeters (cm) is the length of the lower side?
Question (KO): 어떤 사다리꼴의 넓이가 100.62제곱센티미터(㎠)이며, 높이가 5.2센티미터(㎝)이고, 윗변이 아랫변보다 3.4센티미터(㎝) 더 길다고 합니다. 아랫변의 길이는 몇 센티미터(㎝)입니까?

Answer: 17.65

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

Question (EN): When Eunji's classmates stand in 3 lines with the same number of students in each line, Eunji stands at the 3rd from the front and the 6th from the back. Find the total number of students in Eunji's class.
Question (KO): 은지네 반 학생들이 각 줄마다 학생 수가 같도록 3줄로 설 때, 은지는 어느 한 줄의 앞에서 3번째, 뒤에서 6번째에 섭니다. 은지네 반 학생은 총 몇 명인지 구하시오.

Answer: 24

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

Question (EN): How many diagonals are there in the rectangle?
Question (KO): 사각형에 존재하는 모든 대각선의 개수는?

Answer: 2

Solution (Python):
var_a = 4
var_b = 4
var_c = 3
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: Arithmetic calculation

Question (EN): Gyuri takes 5 days to do 1/3 of a job, and Seungyeon takes 2 days to do 1/5 of the same job. If Gyuri and Seungyeon work together, how many days will it take to finish the job?
Question (KO): 규리는 어떤 일의 1/3을 하는 데 5일 걸리고, 승연이는 같은 일의 1/5을 하는 데 2일 걸립니다. 규리와 승연이가 함께 일을 한다면 일을 끝내는 데 며칠이 걸립니까?

Answer: 6

Solution (Python):
var_a = 1
var_b = 0.3333333333333333
var_c = 5
var_d = var_b / var_c
var_e = 0.2
var_f = 2
var_g = var_e / var_f
var_h = var_d + var_g
var_i = var_a / var_h
print(int(eval('{:.2f}'.format(round(var_i+1e-10,2)))))
Category: Arithmetic calculation

Question (EN): There are 3/8 and 0.125. What is the difference between the two numbers?
Question (KO): 3/8, 0.125 총 2개의 숫자가 있습니다. 두 수의 차는?

Answer: 0.25

Solution (Python):
var_a = 0.375
var_b = 0.125
var_c = var_a - var_b
var_d = abs(var_c)
print('{:.2f}'.format(round(var_d+1e-10,2)))
Category: Arithmetic calculation

Question (EN): Taehyung and Namjoon bought 10 pencils each. Taehyung used some of the pencils and gave 3 of the remaining pencils to Namjoon, and Namjoon also used a few, too. Than the two of them had 6 pencils each. Find how many pencils Namjoon used.
Question (KO): 태형이와 남준이는 연필을 각각 10자루씩 샀습니다. 태형이는 그 중 몇 자루를 사용하고 남은 연필 중 3자루를 남준이에게 주었고, 남준이도 몇 자루를 사용하였더니 두 사람이 가지고 있는 연필은 각각 6자루가 되었습니다. 남준이가 사용한 연필은 몇 자루인지 구하시오.

Answer: 7

Solution (Python):
var_a = 10
var_b = 6
var_c = 3
var_d = var_b - var_c
var_e = var_a - var_d
print(int(var_e))
Category: Correspondence

Question (EN): Find A that satisfies the following condition: When 17 is divided by 6, the quotient is 2 and the remainder is A.
Question (KO): 17을 6로 나누면 몫이 2, 나머지가 A가 됩니다. 이 때 A의 값을 구하시오.

Answer: 5

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

Question (EN): There is a two digit number. This number is divisible by 6 and 9, and when divided by 7, the remainder is 1. Find this two digit number.
Question (KO): 두 자리 수가 있습니다. 이 수는 6과 9로 나누어떨어지고, 7로 나누면 나머지가 1이 됩니다. 두 자리 수를 구하시오.

Answer: 36

Solution (Python):
var_a = 10
var_b = 100
var_c = 1
list_a = [i for i in range(var_a, var_b + 1, var_c)]
var_d = 6
var_e = 9
var_f = var_e * var_d / math.gcd(int(var_e), int(var_d))
var_g = 0
list_b = [] 
var_f = int(var_f)
var_g = int(var_g)
if var_g < 0:
    var_g = var_g + var_f
for i in list_a:
    i = int(i)
    if i%var_f == var_g:
        list_b.append(i)
var_h = 7
var_i = 1
list_c = [] 
var_h = int(var_h)
var_i = int(var_i)
if var_i < 0:
    var_i = var_i + var_h
for i in list_b:
    i = int(i)
    if i%var_h == var_i:
        list_c.append(i)
var_j = 1
var_k = list_c[var_j-1]
print(int(var_k))
Category: Arithmetic calculation

Question (EN): A fairy tale book was placed on one side of the two-arm scale, and a 0.5 kilograms (kg) weight and two 0.3 kilograms (kg) weights were placed on the other side, and it was level. How many kilograms (kg) does one children's book weigh?
Question (KO): 양팔 저울의 한쪽에는 동화책 한 권을 올려놓고, 다른 쪽에는 0.5킬로그램(㎏)짜리 추 한 개와 0.3킬로그램(㎏)짜리 추 2개를 올려놓았더니 수평이 되었습니다. 동화책 한 권의 무게는 몇 킬로그램(㎏)입니까?

Answer: 1.1

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

Question (EN): Jina and Jeongyeol are singers. Jina sang for 140 hours in one week, and Jeongyeol sang for 48 hours in two days. Who sang more in one day?
Question (KO): 진아와 정열이는 가수이다. 진아는 1주일 동안 140시간을 노래했고, 정열이는 2일동안 48시간동안 노래를 했다. 하루에 누가 더 노래를 많이 불렀는가?

Answer: Jeongyeol

Solution (Python):
var_a = 'Jina'
var_b = 'Jeongyeol'
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 = 140
var_d = 1
var_e = 7
var_f = var_d * var_e
var_g = var_c / var_f
var_h = 48
var_i = 2
var_j = var_h / var_i
list_b= []
if "/" in str(var_j):
    var_j = eval(str(var_j))
list_b.append(var_j)
if "/" in str(var_g):
    var_g = eval(str(var_g))
list_b.append(var_g)
list_b.reverse()
var_k = 1
list_c=list_b.copy()
list_c.sort()
var_l = list_c[-var_k]
var_m = list_b.index(var_l)+1
var_n = list_a[var_m-1]
print(var_n)
Category: Arithmetic calculation

Question (EN): Among the people in Jimin's class who like Korean, 32 people also like math. There are 38 students who like Korean and 39 students who like math, and all students say they like at least one of the two. How many students are there in Jimin's class?
Question (KO): 지민이네 반에서 국어를 좋아하는 사람 중 수학도 좋아하는 사람은 32명입니다. 국어를 좋아하는 학생은 38명이고 수학을 좋아하는 학생은 39명이고 모든 학생이 최소 둘 중 하나는 좋아한다고 합니다. 지민이네 반 학생은 모두 몇 명입니까?

Answer: 45

Solution (Python):
var_a = 38
var_b = 39
var_c = var_a + var_b
var_d = 32
var_e = var_c - var_d
print(int(var_e))
Category: Comparison

Question (EN): A is 32 plus 7, B is 3 groups of 10 each plus 3 individual pieces, and C is 50 minus 9. Which of the three numbers A, B, and C is the smallest?
Question (KO): A는 32에서 7 더한 수, B는 10개씩 3묶음과 낱개 3개를 더한 수, C는 50에서 9를 뺀 수이다. A, B, C 세 수 중에서 가장 작은 수는 무엇인가?

Answer: B

Solution (Python):
var_a = 'A'
var_b = 'B'
var_c = 'C'
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 = 32
var_e = 7
var_f = var_d + var_e
var_g = 3
var_h = 10
var_i = var_g * var_h
var_j = 3
var_k = var_i + var_j
var_l = 50
var_m = 9
var_n = var_l - var_m
list_b= []
if "/" in str(var_n):
    var_n = eval(str(var_n))
list_b.append(var_n)
if "/" in str(var_k):
    var_k = eval(str(var_k))
list_b.append(var_k)
if "/" in str(var_f):
    var_f = eval(str(var_f))
list_b.append(var_f)
list_b.reverse()
var_o = 1
list_c=list_b.copy()
list_c.sort()
var_p = list_c[var_o-1]
var_q = list_b.index(var_p)+1
var_r = list_a[var_q-1]
print(var_r)
Category: Arithmetic calculation

Question (EN): Adding 8 consecutive even numbers gives 424. Find the last number out of 8 even numbers.
Question (KO): 연속하는 8개의 짝수를 더하였더니 424가 되었습니다. 8개의 짝수 중 마지막 수를 구하시오.

Answer: 60

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

Question (EN): A number is the product of 5 and 7. What is the numbber added by 12 added by 8?
Question (KO): 어떤 수는 5와 7의 곱입니다. 어떤 수에서 12를 더하고 8을 더하면 얼마인지 구하시오.

Answer: 55

Solution (Python):
var_a = 5
var_b = 7
var_c = var_a * var_b
var_d = 12
var_e = var_c + var_d
var_f = 8
var_g = var_e + var_f
print(int(var_g))
Category: Correspondence

Question (EN): There are some decimals up to 2 places after the decimal point. Rounding this number to 2 decimal places gives 1.7. Find the largest of these decimals minus the smallest, including the decimal point.
Question (KO): 소수점 아래 2번째 자리까지 있는 어떤 소수가 있습니다. 이 수를 소수 2번째 자리에서 반올림하면 1.7이 됩니다. 이러한 소수 중 가장 큰 수에서 가장 작은 수를 뺀 값을 소수점을 포함하여 구하시오.

Answer: 0.09

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

Question (EN): When 6AB3 is rounded to the thousandth, it. is 6000. Find the sum of the possible values of A.
Question (KO): 6AB3을 반올림하여 천의 자리까지 나타내면 6000이 됩니다. 가능한 A 값들의 합을 구하시오

Answer: 10

Solution (Python):
var_a = '6AB3'
ans_dict = dict()
var_a = str(var_a)
list_a = []
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
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]))
    if len(var_a) == len(str(int(temp))):
        new_elem = int(temp)
        list_a.append(new_elem)
var_b = 6000
var_c = 500
var_d = var_b - var_c
list_b = []
for i in list_a:
    if i >= var_d:
        list_b.append(i)
var_e = 6000
var_f = 500
var_g = var_e + var_f
list_c = []
for i in list_b:
    if i < var_g:
        list_c.append(i)
var_h = '6AB3'
var_i = 'A'
var_h = str(var_h)
var_i = str(var_i)
unk_idx = var_h.index(var_i)
list_d = []
for elem in list_c:
    elem = str(elem)
    list_d.append(int(elem[unk_idx]))
list_d = list(set(list_d))
list_d = [float(i) for i in list_d]
var_j = sum(list_d)
print(int(var_j))
Category: Geometry

Question (EN): There are 2 number cards. One has 15 written on it, and the other has the value of number on the first card multiplied by 0.9. Find the area of the rectangle whose length and width are the same numbers on these two cards.
Question (KO): 숫자 카드 2장이 있다. 하나는 15가 적혀져 있고, 다른 하나는 처음 카드에 적힌 수에 0.9를 곱한 수가 쓰여 있다. 이 두 카드에 적힌 수를 각각 가로와 세로로 하는 직사각형의 넓이를 구하라.

Answer: 202.5

Solution (Python):
var_a = 15
var_b = 15
var_c = 0.9
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): Eunbi, Jaeyeon, and Jooeun each have their own water bottles with water in them. The sum of the water in the three friends' water bottles is 1 liter (L) and 200 milliliters (㎖). If Jooeun gave Jaeyeon 200 milliliters (ml) of water and Eunbi 100 milliliters (ml) of water, and the three friends have the same amount of water now, find the amount of water that Eunbi's water bottle initially contained.
Question (KO): 은비, 재연, 주은이는 각자의 물병을 가지고 있고, 그 안에는 물이 담겨 있습니다. 세 친구의 물병 속에 담겨 있는 물의 양의 합은 1리터(L) 200밀리리터(㎖)입니다. 주은이가 재연이에게 물 200밀리리터(㎖)를 주고, 은비에게는 물 100밀리리터(㎖)를 줬더니 세 친구가 가진 물의 양이 같아졌다면, 은비의 물병에 처음 담겨 있던 물의 양을 구하시오.

Answer: 300

Solution (Python):
var_a = 1
var_b = 1000
var_c = var_a * var_b
var_d = 200
var_e = var_c + var_d
var_f = 200
var_g = var_e - var_f
var_h = 100
var_i = var_g - var_h
var_j = 3
var_k = var_i / var_j
print(int(var_k))
Category: Geometry

Question (EN): What is the sum of the number of all the faces of a pentahedron?
Question (KO): 오면체의 면수를 모두 더하면 몇인가요?

Answer: 5

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

Question (EN): Yoongi collected 4, and Jungkook collected 6 divided by 3, and Yuna collected 5. Who collected the biggest number?
Question (KO): 윤기는 4, 정국이는 6에서 3을 나눈 몫 만큼 모았고, 유나는 5만큼 모았습니다. 누가 가장 큰 수를 모았습니까?

Answer: Yuna

Solution (Python):
var_a = 'Yoongi'
var_b = 'Jungkook'
var_c = 'Yuna'
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 = 3
var_g = var_e // var_f
var_h = 5
list_b= []
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_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]
var_k = list_b.index(var_j)+1
var_l = list_a[var_k-1]
print(var_l)