philschmid/DMath huggingface dataset:
Category: Correspondence

Question (EN): A certain number equals 5.46 minus 3.97. What is the value of adding 5.46 to the certain number?
Question (KO): 어떤 수는 5.46에서 3.97을 뺀 값이다. 어떤 수에 5.46을 더하면 얼마인가?

Answer: 6.95

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

Question (EN): Seunghyo received 426 milliliters (ml) of medicine from the hospital. The doctor prescribed to take 0.06 of the total medicine per day. How many milliliters (ml) should Seunghyo take?
Question (KO): 승효는 병원에서 약을 426밀리리터(㎖) 받아왔습니다. 의사 선생님께서 하루에 전체 약의 0.06만큼 먹으라고 하셨습니다. 승효는 하루에 몇 밀리리터(㎖)의 약을 먹어야할까요?

Answer: 25.56

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

Question (EN): Find the sum of the four-digit numbers formed by using 2, 4, 5, and 3 once each.
Question (KO): 2, 4, 5, 3을 각각 한 번씩 사용하여 만든 네 자리 수들의 총합을 구하여라.

Answer: 93324

Solution (Python):
var_a = 2
var_b = 4
var_c = 5
var_d = 3
list_a= []
if "/" in str(var_d):
    var_d = eval(str(var_d))
list_a.append(var_d)
if "/" in str(var_c):
    var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
    var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
    var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_e = 4
list_b = [str(i) for i in list_a]
list_b = list(itertools.permutations(list_b, var_e))
list_b = [''.join(num_list) for num_list in list_b]
list_b = [str_num for str_num in list_b if str_num[0] != '0']
list_b = [float(i) for i in list_b]
list_b = [float(i) for i in list_b]
var_f = sum(list_b)
print(int(var_f))
Category: Arithmetic calculation

Question (EN): 254 students are going to be assigned to several buses. If there are 30 people on each bus and there are no seats left, how many more students are needed?
Question (KO): 학생 254명을 버스에 나눠 태우려고 합니다. 버스 한 대에 30명씩 태우고 남는 자리 없이 학생을 태우려고 한다면 학생 몇 명을 더 태워야 하나요?

Answer: 16

Solution (Python):
var_a = 30
var_b = 254
var_c = 30
var_d = var_b % var_c
var_e = var_a - var_d
print(int(var_e))
Category: Arithmetic calculation

Question (EN): In Ilwoong's drive, there are folders numbered 1 to 25, and each folder has 10 subfolders. If there are 8 files in each subfolder, how many files are there in Ilwoong's drive?
Question (KO): 일웅이네 드라이브에는 1번부터 25번 폴더까지 있고, 각 폴더마다 10개의 하위폴더가 있습니다. 각 하위폴더마다 8개의 파일이 있다면, 일웅이네 드라이브에는 모두 몇 개의 파일이 있습니까?

Answer: 2000

Solution (Python):
var_a = 25
var_b = 10
var_c = var_a * var_b
var_d = 8
var_e = var_c * var_d
print(int(var_e))
Category: Possibility

Question (EN): Five rabbits are going to have a picnic at the lake. In this case, if there are 2 lakes, how many ways can a rabbit choose a lake?
Question (KO): 5마리의 토끼가 호수에 소풍을 가려고 합니다. 이때, 2개의 호수가 있을 때 토끼가 호수를 선택하는 경우는 모두 몇 가지입니까?

Answer: 32

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

Question (EN): Sang-jun has 10 more books on economics than a quarter of his total books, 5 fewer books on social studies than 3/5 of the rest, and 12 books on science. If Sang-jun has 13 books that are not economics, social studies, or science, how many books does Sang-jun have in total?
Question (KO): 상준은 경제 분야 책을 전체 책의 4분의 1보다 10권 더 많이 갖고 있다, 사회 분야 책은 나머지 책의 3/5보다 5권 덜 가지고 있고, 12권은 과학 분야 책이다. 상준이가 경제학, 사회, 과학이 아닌 책을 13권 가지고 있다면, 상준은 총 몇 권의 책을 가지고 있습니까?

Answer: 80

Solution (Python):
var_a = 13
var_b = 12
var_c = var_a + var_b
var_d = 5
var_e = var_c - var_d
var_f = 1
var_g = 0.6
var_h = var_f - var_g
var_i = var_e / var_h
var_j = 10
var_k = var_i + var_j
var_l = 1
var_m = 1
var_n = 4
var_o = var_m / var_n
var_p = var_l - var_o
var_q = var_k / var_p
print(int(var_q))
Category: Arithmetic calculation

Question (EN): There are 2 machines in the doll factory. (A) machine makes 256 dolls in 4 hours, and (B) machine makes 111 dolls in 3 hours. How many dolls can you make if you run (A) machine and (B) together for 3 hours at the same speed?
Question (KO): 인형 공장에 기계가 2대 있습니다. 인형을 (가) 기계는 4시간에 256개, (나) 기계는 3시간에 111개를 만듭니다. 같은 빠르기로 3시간 동안 (가) 기계와 (나) 기계를 같이 돌리면 인형을 모두 몇 개 만들 수 있습니까?

Answer: 303

Solution (Python):
var_a = 256
var_b = 3
var_c = 4
var_d = var_b / var_c
var_e = var_a * var_d
var_f = 111
var_g = var_e + var_f
print(int(var_g))
Category: Possibility

Question (EN): You want to create a two-digit number by selecting two different numbers from 7, 4, 0, 3, and 5. Find the sum of the third largest number and the third smallest number possible.
Question (KO): 7, 4, 0, 3, 5 중에서 서로 다른 숫자 2개를 뽑아 두 자리 수를 만들려고 합니다. 만들 수 있는 수 중에서 셋째로 큰 수와 셋째로 작은 수의 합을 구하시오.

Answer: 108

Solution (Python):
var_a = 7
var_b = 4
var_c = 0
var_d = 3
var_e = 5
list_a= []
if "/" in str(var_e):
    var_e = eval(str(var_e))
list_a.append(var_e)
if "/" in str(var_d):
    var_d = eval(str(var_d))
list_a.append(var_d)
if "/" in str(var_c):
    var_c = eval(str(var_c))
list_a.append(var_c)
if "/" in str(var_b):
    var_b = eval(str(var_b))
list_a.append(var_b)
if "/" in str(var_a):
    var_a = eval(str(var_a))
list_a.append(var_a)
list_a.reverse()
var_f = 2
list_b = [str(i) for i in list_a]
list_b = list(itertools.permutations(list_b, var_f))
list_b = [''.join(num_list) for num_list in list_b]
list_b = [str_num for str_num in list_b if str_num[0] != '0']
list_b = [float(i) for i in list_b]
var_g = 3
list_c=list_b.copy()
list_c.sort()
var_h = list_c[-var_g]
var_i = 3
list_d=list_b.copy()
list_d.sort()
var_j = list_d[var_i-1]
var_k = var_h + var_j
print(int(var_k))
Category: Arithmetic calculation

Question (EN): There is a box of 16 dumbbells weighing 17.88 kilograms (kg). If the empty box weighs 0.6 kilograms (kg) and all dumbbells weigh the same, how many kilograms (kg) are 7 dumbbells?
Question (KO): 같은 무게의 아령이 16개 든 상자의 무게는 17.88킬로그램(㎏)입니다. 빈 상자의 무게가 0.6킬로그램(㎏)이라면 아령 7개는 몇 킬로그램(㎏)일까요?

Answer: 7.56

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

Question (EN): Find the difference between the area of a rectangle whose sum of its sides is 38 centimeters (cm) and its width is 15 centimeters (cm) and the rectangle whose sum of its sides is 36 centimeters (cm).
Question (KO): 네 변의 길이의 합이 38센티미터(㎝)이고 가로가 15센티미터(㎝)인 직사각형과 네 변의 길이의 합이 36센티미터(㎝)인 직사각형의 넓이의 차를 구하시오.

Answer: 21

Solution (Python):
var_a = 36
var_b = 4
var_c = var_a / var_b
var_d = 2
var_e = var_c ** var_d
var_f = 38
var_g = 2
var_h = var_f / var_g
var_i = 15
var_j = var_h - var_i
var_k = 15
var_l = var_j * var_k
var_m = var_e - var_l
var_n = abs(var_m)
print(int(var_n))
Category: Arithmetic calculation

Question (EN): In a toy factory, machine A takes 3 hours to make 1 toy, and machine B takes 5 hours to make 1 toy. Find the time it took to make 16 toys with the two machines.
Question (KO): 장난감 공장에서 기계 A는 장난감 1개를 만드는데 3시간이 걸리고, 기계 B는 장난감 1개를 만드는데 5시간이 걸린다. 두 기계로 장난감 16개를 만드는데 걸린 시간이 얼마인지 구하시오.

Answer: 30

Solution (Python):
var_a = 1
var_b = 16
var_c = var_a * var_b
var_d = 1
var_e = 5
var_f = var_d / var_e
var_g = 1
var_h = 3
var_i = var_g / var_h
var_j = var_f + var_i
var_k = var_c / var_j
print(int(var_k))
Category: Arithmetic calculation

Question (EN): There are three schools A, B and C. The sum of the students in schools A and C is 210. If the number of students in school A is 4 times the number of students in school B, and the number of students in school C is 3 times the number of students in school B, what is the number of students in school B?
Question (KO): A,B,C 세 학교가 있습니다. A와 C학교 학생수의 합은 210입니다. A학교의 학생수는 B학교 학생수의 4배이고, C학교의 학생수는 B학교 학생수의 3배일때 B학교 학생수는 몇 명인가?

Answer: 30

Solution (Python):
var_a = 210
var_b = 4
var_c = 3
var_d = var_b + var_c
var_e = var_a / var_d
print(int(var_e))
Category: Comparison

Question (EN): The distance from Jimin's house to the school is 2 kilometers (km) and 280 meters (m), and the distance to the hospital is 4125 meters (m). Which is farther from Jimin's house, the hospital or the school?
Question (KO): 지민이네 집에서 학교까지의 거리는 2킬로미터(㎞) 280미터(m)이고, 병원까지의 거리는 4125미터(m)입니다. 병원과 학교 중 지민이네 집에서 더 먼 곳은 어디입니까?

Answer: hospital

Solution (Python):
var_a = 'school'
var_b = 'hospital'
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 = 2
var_d = 1000
var_e = var_c * var_d
var_f = 280
var_g = var_e + var_f
var_h = 4125
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)
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): If you divide a number by 5 and 6, you divide it and if you divide by 7, the rest is 6. Find the largest four-digit number in any number.
Question (KO): 어떤 수를 5와 6으로 나누면 나누어떨어지고 7로 나누면 나머지가 6이라고 합니다. 어떤 수 중에서 가장 큰 네 자리 수를 구하시오.

Answer: 9960

Solution (Python):
var_a = 1000
var_b = 9999
var_c = 1
list_a = [i for i in range(var_a, var_b + 1, var_c)]
var_d = 5
var_e = 6
var_f = var_e * var_d / math.gcd(int(var_e), int(var_d))
list_b = []
var_f = int(var_f)
for i in list_a:
    i = int(i)
    if i % var_f == 0:
        list_b.append(i)
var_g = 7
var_h = 6
list_c = [] 
var_g = int(var_g)
var_h = int(var_h)
if var_h < 0:
    var_h = var_h + var_g
for i in list_b:
    i = int(i)
    if i%var_g == var_h:
        list_c.append(i)
var_i = 1
list_d=list_c.copy()
list_d.sort()
var_j = list_d[-var_i]
print(int(var_j))
Category: Comparison

Question (EN): A bakery sold 40 boxes of cookies maintaining 28 for each, and 65 boxes of macarons that have 15 for each. Which item was sold more: cookies or macarons?
Question (KO): 28개씩 들어있는 쿠키 상자는 40상자를 팔았고, 15개씩 들어있는 마카롱 상자는 65상자를 팔았습니다. 쿠키와 마카롱 중 더 많이 팔린 것은 무엇입니까?

Answer: cookies

Solution (Python):
var_a = 'cookies'
var_b = 'macarons'
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 = 28
var_d = 40
var_e = var_c * var_d
var_f = 15
var_g = 65
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): Hoseok's average score in Korean, English, and Science is 89. If Hoseok's average score increases by 1 after taking the Social studies test, what is the score of Social studies?
Question (KO): 호석이의 국어, 영어, 과학의 평균 점수는 89점입니다. 호석이가 사회 시험을 본 후 평균 점수가 1점 올랐다고 할 때, 호석이의 사회 점수는 몇 점입니까?

Answer: 93

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

Question (EN): Jeong-ho wants to collect lots of square-shaped papers with sides measuring 24 centimeters (cm). How many pieces can you make by cutting a piece of drawing paper that is 172 centimeters (cm) wide and 295 centimeters (cm) long?
Question (KO): 정호는 한 변의 길이가 24센티미터(㎝)인 정사각형 모양의 종이를 많이 모으려고 한다. 가로 172센티미터(㎝), 세로 295센티미터(㎝)인 도화지를 잘라서 만드려고 할 때, 몇 개까지 만들 수 있는가?

Answer: 84

Solution (Python):
var_a = 172
var_b = 24
var_c = var_a // var_b
var_d = 295
var_e = 24
var_f = var_d // var_e
var_g = var_c * var_f
print(int(var_g))
Category: Comparison

Question (EN): Seokjin went to the swimming competition and came in 8th. What is the number of people who came in faster than Seokjin?
Question (KO): 석진이는 수영 시합에 나갔는데 8번째로 들어왔습니다. 석진이보다 빨리 들어온 사람은 몇 명입니까?

Answer: 7

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

Question (EN): Find the smallest natural number A that satisfies the equation 360÷(A×A×A/B)=5.
Question (KO): 360÷(A×A×A/B)=5의 식을 만족하는 가장 작은 자연수 A를 구하여라.

Answer: 6

Solution (Python):
var_a = '360÷(A×A×A/B)=5'
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] = []
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].append(int(c[i]))
list_a = list(set(ans_dict[var_b]))
var_c = 1
list_b=list_a.copy()
list_b.sort()
var_d = list_b[var_c-1]
print(int(var_d))
Category: Comparison

Question (EN): Yuna was 7th in line at the mart, and Yoojeong was right behind her. What number of position is Yoojung standing?
Question (KO): 유나는 마트에서 7번째로 줄을 섰고, 유정이는 바로 뒤에 줄을 섰습니다. 유정이는 몇 번째로 섰습니까?

Answer: 8

Solution (Python):
var_a = 7
var_b = 1
var_c = var_a + var_b
print(int(var_c))
Category: Correspondence

Question (EN): If the two decimal numbers 12.4A is less than 12.45, how many digits can fit in A?
Question (KO): 소수 두 자리 수 12.4A<12.45보다 작다고 할 때, A에 들어갈 수 있는 숫자의 개수는 몇 개입니까?

Answer: 5

Solution (Python):
var_a = '12.4A<12.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] = []
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].append(int(c[i]))
list_a = list(set(ans_dict[var_b]))
var_c = len(list_a)
print(int(var_c))
Category: Arithmetic calculation

Question (EN): A red paper tape is 20 centimeters (cm) long and a purple paper tape is 16 centimeters (cm) long. Find out the average length of the two paper tapes in centimeters (cm).
Question (KO): 빨간색 종이테이프는 20센티미터(㎝)이고, 보라색 종이테이프는 16센티미터(㎝)입니다. 두 종이테이프는 평균 몇 센티미터(㎝)입니까?

Answer: 18

Solution (Python):
var_a = 20
var_b = 16
var_c = var_a + var_b
var_d = 2
var_e = var_c / var_d
print(int(var_e))
Category: Geometry

Question (EN): You are going to make a square shape with colored tape that is 100 centimeters (cm) long. How many centimeters (cm) should each side be?
Question (KO): 길이가 100센티미터(㎝)인 색테이프로 정사각형 모양을 만들려고 합니다. 한 변의 길이는 몇 센티미터(㎝)로 해야 합니까?

Answer: 25

Solution (Python):
var_a = 100
var_b = 4
var_c = var_a / var_b
print(int(var_c))
Category: Correspondence

Question (EN): I used the same length of ribbon while wrapping 7 presents. The length of the ribbon used is 50.68 centimeters (cm). Find how many centimeters (cm) of ribbon were used to wrap one gift.
Question (KO): 7개의 선물을 포장하면서 동일한 길이의 리본을 사용했습니다. 사용한 리본의 길이는 50.68센티미터(㎝) 입니다. 하나의 선물을 포장하는데 사용한 리본은 몇 센티미터(㎝)인지 구하십시오.

Answer: 7.24

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

Question (EN): Yuna's average score in Korean and English is 92 points. If Yuna's overall average score increases by 2 points after taking the math test, what is Yuna's math score?
Question (KO): 유나의 국어와 영어의 평균 점수는 92점입니다. 유나가 수학 시험을 본 후, 유나의 전체 평균 점수가 2점 올랐다고 할 때, 유나의 수학 점수는 몇 점입니까?

Answer: 98

Solution (Python):
var_a = 92
var_b = 2
var_c = var_a + var_b
var_d = 3
var_e = var_c * var_d
var_f = 92
var_g = 2
var_h = var_f * var_g
var_i = var_e - var_h
print(int(var_i))
Category: Arithmetic calculation

Question (EN): One dozen of pencils is 12 pencils. 11 students took 3 pencils each from 3 dozen pencils. How many pencils are left after students took them?
Question (KO): 연필 1타는 12자루입니다. 연필 3타를 학생 11명이 3자루씩 나누어 가졌습니다. 학생들이 나누어 가지고 남은 연필은 몇 자루입니까?

Answer: 3

Solution (Python):
var_a = 12
var_b = 3
var_c = var_a * var_b
var_d = 11
var_e = 3
var_f = var_d * var_e
var_g = var_c - var_f
print(int(var_g))
Category: Arithmetic calculation

Question (EN): How many times does the number 3 appear from 1 to 31?
Question (KO): 1부터 31까지 숫자 3은 몇 번 등장합니까?

Answer: 6

Solution (Python):
var_a = 1
var_b = 31
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 = 3
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
var_g = 1
var_h = var_f + var_g
print(int(var_h))
Category: Geometry

Question (EN): What is the area in square centimeters (cm2) of a rectangle that can be formed by attaching 3.2 squares with sides of 8.5 centimeters (cm) in a row?
Question (KO): 한 변의 길이가 8.5센티미터(㎝)인 정사각형 3.2개를 일렬로 붙여서 만들 수 있는 직사각형의 넓이는 몇 제곱센티미터(㎠)입니까?

Answer: 231.2

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

Question (EN): 24 sheets of colored paper and 18 sheets of drawing paper will be distributed equally to as many students as possible. How many people can get the papers?
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: Comparison

Question (EN): In a line of 27 people, if Minyoung is standing in the13th from the back, where is she placed from the front?
Question (KO): 27명이 서있는 줄에서 민영이는 뒤에서 13번째에 서있을 때, 앞에서는 몇 번째인지 구하시오.

Answer: 15

Solution (Python):
var_a = 27
var_b = 13
var_c = var_a - var_b
var_d = 1
var_e = var_c + var_d
print(int(var_e))
Category: Possibility

Question (EN): If one blue ball is removed from a box containing 3 red balls, 2 blue balls and 5 yellow balls, what is the number of red balls?
Question (KO): 빨간 공 3개, 파란 공 2개, 노란 공 5개가 담겨져 있는 상자에서 파란 공 1개를 뺐을 때, 빨간 공의 개수는?

Answer: 3

Solution (Python):
var_a = 3
print(int(var_a))
Category: Possibility

Question (EN): How many four-digit numbers can be formed by using all even numbers less than or equal to 9 once?
Question (KO): 9 이하의 짝수를 한 번씩 모두 사용하여 만들 수 있는 네 자리 수는 총 몇 가지 입니까?

Answer: 96

Solution (Python):
var_a = 0
var_b = 9
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)
var_c = 4
list_b = [str(i) for i in list_a]
list_b = list(itertools.permutations(list_b, var_c))
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_d = len(list_b)
print(int(var_d))
Category: Arithmetic calculation

Question (EN): There were some tangerines in the basket. Eunji ate 9 pieces, and mother put 5 more in the basket, and it became 20 pieces. How many tangerines were in the basket at the beginning?
Question (KO): 바구니에 귤이 몇 개 있었습니다. 은지가 9개를 먹고 어머니께서 5개를 바구니에 더 넣었더니 20개가 되었습니다. 처음에 바구니에 있던 귤은 몇 개입니까?

Answer: 24

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

Question (EN): If you weigh on the moon, it is said to be 1/6 of your weight on Earth. Yeonjin weighed 50 kilograms (kg) on Earth, and Hodong weighed 8 and 4/6 kilograms (kg) when measured on the moon. Find the answer of who weighs more on the moon.
Question (KO): 달에서 몸무게를 재면 지구에서 재는 몸무게의 1/6이라고 합니다. 연진이는 지구에서 몸무게를 쟀더니 50킬로그램(㎏)이었고, 호동이는 달에서 쟀더니 몸무게가 8과 4/6킬로그램(㎏)이었습니다. 달에서 잰 몸무게는 누가 더 많이 나가는지 답을 구하세요.

Answer: Hodong

Solution (Python):
var_a = 'Yeonjin'
var_b = 'Hodong'
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 = 50
var_d = 0.16666666666666666
var_e = var_c * var_d
var_f = 8
var_g = 0.6666666666666666
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: Correspondence

Question (EN): Among the natural numbers between 200 and 500, find the value whose remainder when divided by 5 is 2, when divided by 8 is 3, and when divided by 9 is 0.
Question (KO): 200이상 500이하의 자연수 중 5로 나눈 나머지가 2이고, 8로 나눈 나머지가 3이고 9로 나눈 나머지가 0인 값을 구하시오.

Answer: 387

Solution (Python):
var_a = 200
var_b = 500
var_c = 1
list_a = [i for i in range(var_a, var_b + 1, var_c)]
var_d = 5
var_e = 2
list_b = [] 
var_d = int(var_d)
var_e = int(var_e)
if var_e < 0:
    var_e = var_e + var_d
for i in list_a:
    i = int(i)
    if i%var_d == var_e:
        list_b.append(i)
var_f = 8
var_g = 3
list_c = [] 
var_f = int(var_f)
var_g = int(var_g)
if var_g < 0:
    var_g = var_g + var_f
for i in list_b:
    i = int(i)
    if i%var_f == var_g:
        list_c.append(i)
var_h = 9
var_i = 0
list_d = [] 
var_h = int(var_h)
var_i = int(var_i)
if var_i < 0:
    var_i = var_i + var_h
for i in list_c:
    i = int(i)
    if i%var_h == var_i:
        list_d.append(i)
var_j = 1
var_k = list_d[var_j-1]
print(int(var_k))