task_id
stringlengths
8
11
language
stringclasses
1 value
prompt
stringlengths
67
820
description
stringlengths
12
628
test
stringlengths
134
152
entry_point
stringclasses
1 value
canonical_solution
stringlengths
46
582
MathQA/1800
python
def problem(): """ the price of a t . v . set worth rs . 70000 is to be paid in 20 installments of rs . 1000 each . if the rate of interest be 6 % per annum , and the first installment be paid at the time of purchase , then the value of the last installment covering the interest as well will be ? n0 = 70000.0 n1 = 20.0 n2 = 1000.0 n3 = 6.0 """
the price of a t . v . set worth rs . 70000 is to be paid in 20 installments of rs . 1000 each . if the rate of interest be 6 % per annum , and the first installment be paid at the time of purchase , then the value of the last installment covering the interest as well will be ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 69000.0) def check(x): pass
problem
n0 = 70000.0 n1 = 20.0 n2 = 1000.0 n3 = 6.0 answer = n0 - n2 return answer
MathQA/1801
python
def problem(): """ the original price of a suit is $ 200 . the price increased 20 % , and after this increase , the store published a 20 % off coupon for a one - day sale . given that the consumers who used the coupon on sale day were getting 20 % off the increased price , how much did these consumers pay for the suit ? n0 = 200.0 n1 = 20.0 n2 = 20.0 n3 = 20.0 """
the original price of a suit is $ 200 . the price increased 20 % , and after this increase , the store published a 20 % off coupon for a one - day sale . given that the consumers who used the coupon on sale day were getting 20 % off the increased price , how much did these consumers pay for the suit ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 192.0) def check(x): pass
problem
n0 = 200.0 n1 = 20.0 n2 = 20.0 n3 = 20.0 t0 = n0 * n1 t1 = t0 / 100.0 t2 = n0 + t1 t3 = n1 * t2 t4 = t3 / 100.0 answer = t2 - t4 return answer
MathQA/1802
python
def problem(): """ in a basketball game , dhoni scored 30 points more than dravid , but only half as many points as shewag . if the 3 players scored a combined total of 150 points , how many points did dhoni score ? n0 = 30.0 n1 = 3.0 n2 = 150.0 """
in a basketball game , dhoni scored 30 points more than dravid , but only half as many points as shewag . if the 3 players scored a combined total of 150 points , how many points did dhoni score ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 45.0) def check(x): pass
problem
n0 = 30.0 n1 = 3.0 n2 = 150.0 t0 = n0 + n2 t1 = 1.0 + 2.0 t2 = t1 + 1.0 answer = t0 / t2 return answer
MathQA/1803
python
def problem(): """ on a partly cloudy day , milton decides to walk back from work . when it is sunny , he walks at a speed of s miles / hr ( s is an integer ) and when it gets cloudy , he increases his speed to ( s + 1 ) miles / hr . if his average speed for the entire distance is 2.8 miles / hr , what fraction of the total distance did he cover while the sun was shining on him ? n0 = 1.0 n1 = 2.8 """
on a partly cloudy day , milton decides to walk back from work . when it is sunny , he walks at a speed of s miles / hr ( s is an integer ) and when it gets cloudy , he increases his speed to ( s + 1 ) miles / hr . if his average speed for the entire distance is 2.8 miles / hr , what fraction of the total distance did he cover while the sun was shining on him ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 0.14285714285714288) def check(x): pass
problem
n0 = 1.0 n1 = 2.8 t0 = n1 + n1 t1 = n1 + t0 t2 = t1 + t0 t3 = t2 / 2.0 answer = n0 / t3 return answer
MathQA/1804
python
def problem(): """ if the sample interest on a sum of money 10 % per annum for 2 years is $ 1200 , find the compound interest on the same sum for the same period at the same rate ? n0 = 10.0 n1 = 2.0 n2 = 1200.0 """
if the sample interest on a sum of money 10 % per annum for 2 years is $ 1200 , find the compound interest on the same sum for the same period at the same rate ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 1260.0) def check(x): pass
problem
n0 = 10.0 n1 = 2.0 n2 = 1200.0 t0 = n2 * 100.0 t1 = n0 * n1 t2 = t0 / t1 t3 = n0 * t2 t4 = t3 / 100.0 t5 = t2 + t4 t6 = n0 * t5 t7 = t6 / 100.0 t8 = t5 + t7 answer = t8 - t2 return answer
MathQA/1805
python
def problem(): """ if 35 % of a number is 12 less than 50 % of that number , then the number is ? n0 = 35.0 n1 = 12.0 n2 = 50.0 """
if 35 % of a number is 12 less than 50 % of that number , then the number is ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 80.0) def check(x): pass
problem
n0 = 35.0 n1 = 12.0 n2 = 50.0 t0 = n2 - n0 t1 = t0 / 100.0 answer = n1 / t1 return answer
MathQA/1806
python
def problem(): """ rs 50000 is divided into two parts one part is given to a person with 10 % interest and another part is given to a person with 20 % interest . at the end of first year he gets profit 8000 find money given by 10 % ? n0 = 50000.0 n1 = 10.0 n2 = 20.0 n3 = 8000.0 n4 = 10.0 """
rs 50000 is divided into two parts one part is given to a person with 10 % interest and another part is given to a person with 20 % interest . at the end of first year he gets profit 8000 find money given by 10 % ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 20000.0) def check(x): pass
problem
n0 = 50000.0 n1 = 10.0 n2 = 20.0 n3 = 8000.0 n4 = 10.0 t0 = n1 / 100.0 t1 = n0 * n2 t2 = t1 / 100.0 t3 = t2 - n3 answer = t3 / t0 return answer
MathQA/1807
python
def problem(): """ a number when divided by a certain divisor left remainder 245 , when twice the number was divided by the same divisor , the remainder was 112 . find the divisor ? n0 = 245.0 n1 = 112.0 """
a number when divided by a certain divisor left remainder 245 , when twice the number was divided by the same divisor , the remainder was 112 . find the divisor ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 378.0) def check(x): pass
problem
n0 = 245.0 n1 = 112.0 t0 = n0 * 2.0 answer = t0 - n1 return answer
MathQA/1808
python
def problem(): """ 85 white and black tiles will be used to form a 10 x 10 square pattern . if there must be at least one black tile in every row and at least one white tile in every column , what is the maximum difference between the number of black and white tiles that can be used ? n0 = 85.0 n1 = 10.0 n2 = 10.0 """
85 white and black tiles will be used to form a 10 x 10 square pattern . if there must be at least one black tile in every row and at least one white tile in every column , what is the maximum difference between the number of black and white tiles that can be used ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 75.0) def check(x): pass
problem
n0 = 85.0 n1 = 10.0 n2 = 10.0 answer = n0 - n1 return answer
MathQA/1809
python
def problem(): """ the parameter of a square is equal to the perimeter of a rectangle of length 16 cm and breadth 14 cm . find the circumference of a semicircle whose diameter is equal to the side of the square . ( round off your answer to two decimal places n0 = 16.0 n1 = 14.0 """
the parameter of a square is equal to the perimeter of a rectangle of length 16 cm and breadth 14 cm . find the circumference of a semicircle whose diameter is equal to the side of the square . ( round off your answer to two decimal places
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 23.561944901923447) def check(x): pass
problem
import math n0 = 16.0 n1 = 14.0 t0 = 2 * (n0 + n1) # perimetere of rectangle t1 = t0 / 4. # square edge given perimeter t2 = t1 / 2.0 t3 = 2 * math.pi * t2 answer = t3 / 2.0 return answer
MathQA/1810
python
def problem(): """ a flagstaff 17.5 m high casts a shadow of length 40.25 m . the height of the building , which casts a shadow of length 28.75 m under similar conditions will be : n0 = 17.5 n1 = 40.25 n2 = 28.75 """
a flagstaff 17.5 m high casts a shadow of length 40.25 m . the height of the building , which casts a shadow of length 28.75 m under similar conditions will be :
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 12.5) def check(x): pass
problem
n0 = 17.5 n1 = 40.25 n2 = 28.75 t0 = n0 / n1 answer = n2 * t0 return answer
MathQA/1811
python
def problem(): """ x can do a piece of work in 4 hours ; y and z together can do it in 3 hours , while x and z together can do it in 2 hours . how long will y alone take to do it ? n0 = 4.0 n1 = 3.0 n2 = 2.0 """
x can do a piece of work in 4 hours ; y and z together can do it in 3 hours , while x and z together can do it in 2 hours . how long will y alone take to do it ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 12.000000000000004) def check(x): pass
problem
n0 = 4.0 n1 = 3.0 n2 = 2.0 t0 = 1.0 / n1 t1 = 1.0 / n2 t2 = 1.0 / n0 t3 = t1 - t2 t4 = t0 - t3 answer = 1 / t4 return answer
MathQA/1812
python
def problem(): """ in a certain company 20 % of the men and 40 % of the women attended the annual company picnic . if 40 % of all the employees are men . what % of all the employee went to the picnic ? n0 = 20.0 n1 = 40.0 n2 = 40.0 """
in a certain company 20 % of the men and 40 % of the women attended the annual company picnic . if 40 % of all the employees are men . what % of all the employee went to the picnic ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 32.0) def check(x): pass
problem
n0 = 20.0 n1 = 40.0 n2 = 40.0 t0 = n2 / 100.0 t1 = n0 / 100.0 t2 = n1 / 100.0 t3 = 100.0 - n2 t4 = t3 / 100.0 t5 = t0 * t1 t6 = t4 * t2 t7 = t5 + t6 answer = t7 * 100.0 return answer
MathQA/1813
python
def problem(): """ excluding stoppages , the speed of a bus is 84 kmph and including stoppages , it is 70 kmph . for how many minutes does the bus stop per hour ? n0 = 84.0 n1 = 70.0 """
excluding stoppages , the speed of a bus is 84 kmph and including stoppages , it is 70 kmph . for how many minutes does the bus stop per hour ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 10.0) def check(x): pass
problem
n0 = 84.0 n1 = 70.0 t0 = n0 - n1 t1 = t0 / n0 answer = t1 * 60.0 return answer
MathQA/1814
python
def problem(): """ 40 is what percent of 160 ? n0 = 40.0 n1 = 160.0 """
40 is what percent of 160 ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 25.0) def check(x): pass
problem
n0 = 40.0 n1 = 160.0 t0 = n0 / n1 answer = t0 * 100.0 return answer
MathQA/1815
python
def problem(): """ the l . c . m of 22 , 54 , 108 , 135 and 198 is n0 = 22.0 n1 = 54.0 n2 = 108.0 n3 = 135.0 n4 = 198.0 """
the l . c . m of 22 , 54 , 108 , 135 and 198 is
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 5940.0) def check(x): pass
problem
n0 = 22.0 n1 = 54.0 n2 = 108.0 n3 = 135.0 n4 = 198.0 t0 = n0 / 2.0 t1 = n3 / 3.0 t2 = 2.0 * 2.0 t3 = 3.0 * 3.0 t4 = t1 / 3.0 t5 = t3 * 3.0 t6 = t4 / 3.0 t7 = t2 * t5 t8 = t6 * t7 answer = t0 * t8 return answer
MathQA/1816
python
def problem(): """ the sale price sarees listed for rs . 280 after successive discount is 12 % and 8 % is ? n0 = 280.0 n1 = 12.0 n2 = 8.0 """
the sale price sarees listed for rs . 280 after successive discount is 12 % and 8 % is ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 226.68800000000002) def check(x): pass
problem
n0 = 280.0 n1 = 12.0 n2 = 8.0 t0 = n0 * n1 t1 = t0 / 100.0 t2 = n0 - t1 t3 = n2 * t2 t4 = t3 / 100.0 answer = t2 - t4 return answer
MathQA/1817
python
def problem(): """ a girl sitting in a train which is travelling at 40 kmph observes that a goods train travelling in a opposite direction , takes 12 seconds to pass him . if the goods train is 1120 m long , find its speed . n0 = 40.0 n1 = 12.0 n2 = 1120.0 """
a girl sitting in a train which is travelling at 40 kmph observes that a goods train travelling in a opposite direction , takes 12 seconds to pass him . if the goods train is 1120 m long , find its speed .
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 295.973122150228) def check(x): pass
problem
n0 = 40.0 n1 = 12.0 n2 = 1120.0 t0 = n2 / n1 t1 = t0 / 0.2778 answer = t1 - n0 return answer
MathQA/1818
python
def problem(): """ a certain list consists of 21 different numbers . if n is in the list and n is 4 times the average ( arithmetic mean ) of the other 20 numbers in the list , then n is what fraction t of the sum of the 21 numbers in the list ? n0 = 21.0 n1 = 4.0 n2 = 20.0 n3 = 21.0 """
a certain list consists of 21 different numbers . if n is in the list and n is 4 times the average ( arithmetic mean ) of the other 20 numbers in the list , then n is what fraction t of the sum of the 21 numbers in the list ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 0.16666666666666666) def check(x): pass
problem
n0 = 21.0 n1 = 4.0 n2 = 20.0 n3 = 21.0 t0 = n2 / n1 t1 = 1.0 * 1.0 t2 = n0 + t0 t3 = t2 / n1 t4 = t3 * 2.0 t5 = t4 - n1 t6 = t5 - 3.0 answer = t1 / t6 return answer
MathQA/1819
python
def problem(): """ a sum was put at simple interest at certain rate for 3 years . had it been put at 1 % higher rate it would have fetched rs . 66 more . the sum is : a . rs . 2,400 b . rs . 2,100 c . rs . 2,200 d . rs . 2,480 n0 = 3.0 n1 = 1.0 n2 = 66.0 n3 = 2400.0 n4 = 2100.0 n5 = 2200.0 n6 = 2480.0 """
a sum was put at simple interest at certain rate for 3 years . had it been put at 1 % higher rate it would have fetched rs . 66 more . the sum is : a . rs . 2,400 b . rs . 2,100 c . rs . 2,200 d . rs . 2,480
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 2200.0) def check(x): pass
problem
n0 = 3.0 n1 = 1.0 n2 = 66.0 n3 = 2400.0 n4 = 2100.0 n5 = 2200.0 n6 = 2480.0 t0 = n2 / n0 answer = t0 * 100.0 return answer
MathQA/1820
python
def problem(): """ find the least number of complete years in which a sum of money put out at 45 % compound interest will be more than double of itself ? n0 = 45.0 """
find the least number of complete years in which a sum of money put out at 45 % compound interest will be more than double of itself ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 2.0) def check(x): pass
problem
import math n0 = 45.0 t0 = n0 / 100.0 t1 = math.log(max(1e-5, 2.0), 2) t2 = t0 + 1.0 t3 = math.log(max(1e-5, t2), 2) t4 = t1 / t3 t5 = t4 + 1.0 answer = math.floor(t5) return answer
MathQA/1821
python
def problem(): """ the speed of the boat in still water in 12 kmph . it can travel downstream through 45 kms in 3 hrs . in what time would it cover the same distance upstream ? n0 = 12.0 n1 = 45.0 n2 = 3.0 """
the speed of the boat in still water in 12 kmph . it can travel downstream through 45 kms in 3 hrs . in what time would it cover the same distance upstream ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 5.0) def check(x): pass
problem
n0 = 12.0 n1 = 45.0 n2 = 3.0 t0 = n1 / n2 t1 = t0 - n0 t2 = n0 - t1 answer = n1 / t2 return answer
MathQA/1822
python
def problem(): """ the avg weight of a , b & c is 55 kg . if d joins the group , the avg weight of the group becomes 60 kg . if another man e who weights is 3 kg more than d replaces a , then the avgof b , c , d & e becomes 58 kg . what is the weight of a ? n0 = 55.0 n1 = 60.0 n2 = 3.0 n3 = 58.0 """
the avg weight of a , b & c is 55 kg . if d joins the group , the avg weight of the group becomes 60 kg . if another man e who weights is 3 kg more than d replaces a , then the avgof b , c , d & e becomes 58 kg . what is the weight of a ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 86.0) def check(x): pass
problem
n0 = 55.0 n1 = 60.0 n2 = 3.0 n3 = 58.0 t0 = n1 * 4.0 t1 = n3 * 4.0 t2 = n0 * n2 t3 = t0 - t2 t4 = n2 + t3 t5 = t1 - t4 answer = t0 - t5 return answer
MathQA/1823
python
def problem(): """ a train 120 m in length crosses a telegraph post in 12 seconds . the speed of the train is ? n0 = 120.0 n1 = 12.0 """
a train 120 m in length crosses a telegraph post in 12 seconds . the speed of the train is ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 36.0) def check(x): pass
problem
n0 = 120.0 n1 = 12.0 t0 = n0 / n1 answer = t0 * 3.6 return answer
MathQA/1824
python
def problem(): """ if ' a ' completes a piece of work in 3 days , which ' b ' completes it in 5 days and ' c ' takes 10 days to complete the same work . how long will they take to complete the work , if they work together ? n0 = 3.0 n1 = 5.0 n2 = 10.0 """
if ' a ' completes a piece of work in 3 days , which ' b ' completes it in 5 days and ' c ' takes 10 days to complete the same work . how long will they take to complete the work , if they work together ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 1.5) def check(x): pass
problem
n0 = 3.0 n1 = 5.0 n2 = 10.0 t0 = n1 / n2 t1 = n0 - 2.0 answer = t0 + t1 return answer
MathQA/1825
python
def problem(): """ a certain drink of type a is prepared by mixing 4 parts milk with 3 parts fruit juice . another drink of type b is prepared by mixing 4 parts of fruit juice and 3 parts of milk . how many liters of fruit juice must be added to 105 liters of drink a to convert it to drink b ? n0 = 4.0 n1 = 3.0 n2 = 4.0 n3 = 3.0 n4 = 105.0 """
a certain drink of type a is prepared by mixing 4 parts milk with 3 parts fruit juice . another drink of type b is prepared by mixing 4 parts of fruit juice and 3 parts of milk . how many liters of fruit juice must be added to 105 liters of drink a to convert it to drink b ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 35.0) def check(x): pass
problem
n0 = 4.0 n1 = 3.0 n2 = 4.0 n3 = 3.0 n4 = 105.0 t0 = n0 + n1 t1 = n0 / t0 t2 = n1 / t0 t3 = n4 * t1 t4 = n4 * t2 t5 = n0 * t3 t6 = t5 / n1 answer = t6 - t4 return answer
MathQA/1826
python
def problem(): """ at what rate percent per annum will a sum of money double in 9 years . n0 = 9.0 """
at what rate percent per annum will a sum of money double in 9 years .
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 11.11111111111111) def check(x): pass
problem
n0 = 9.0 answer = 100.0 / n0 return answer
MathQA/1827
python
def problem(): """ noelle walks from point a to point b at an average speed of 3 kilometers per hour . at what speed , in kilometers per hour , must noelle walk from point b to point a so that her average speed for the entire trip is 4 kilometers per hour ? n0 = 3.0 n1 = 4.0 """
noelle walks from point a to point b at an average speed of 3 kilometers per hour . at what speed , in kilometers per hour , must noelle walk from point b to point a so that her average speed for the entire trip is 4 kilometers per hour ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 6.0) def check(x): pass
problem
n0 = 3.0 n1 = 4.0 t0 = n0 * n1 t1 = n0 * 2.0 t2 = t1 - n1 answer = t0 / t2 return answer
MathQA/1828
python
def problem(): """ the product of x and y is a constant . if the value of x is increased by 40 % , by what percentage must the value of y be decreased ? n0 = 40.0 """
the product of x and y is a constant . if the value of x is increased by 40 % , by what percentage must the value of y be decreased ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 28.57142857142857) def check(x): pass
problem
n0 = 40.0 t0 = n0 + 100.0 t1 = 100.0 / t0 t2 = 1.0 - t1 answer = t2 * 100.0 return answer
MathQA/1829
python
def problem(): """ if a and b are the roots of the equation x 2 - 6 x + 6 = 0 , then the value of a 2 + b 2 is : n0 = 2.0 n1 = 6.0 n2 = 6.0 n3 = 0.0 n4 = 2.0 n5 = 2.0 """
if a and b are the roots of the equation x 2 - 6 x + 6 = 0 , then the value of a 2 + b 2 is :
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 23.999999999999993) def check(x): pass
problem
import math n0 = 2.0 n1 = 6.0 n2 = 6.0 n3 = 0.0 n4 = 2.0 n5 = 2.0 t0 = n1 * 4.0 t1 = n1**min(n0, 5) t2 = t1 - t0 t3 = math.sqrt(max(0, t2)) t4 = n1 + t3 t5 = n1 - t3 t6 = t5 / n0 t7 = t4 / n0 t8 = t6**min(n0, 5) t9 = t7**min(n0, 5) answer = t8 + t9 return answer
MathQA/1830
python
def problem(): """ 6 persons in an organization including x and y were to be divided in two groups of 3 members each . the total number of groups containing both x and y is what fraction of the total number of groups which can be formed ? n0 = 6.0 n1 = 3.0 """
6 persons in an organization including x and y were to be divided in two groups of 3 members each . the total number of groups containing both x and y is what fraction of the total number of groups which can be formed ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 0.3) def check(x): pass
problem
import math n0 = 6.0 n1 = 3.0 t0 = math.factorial(min(15, int(n1))) t1 = n0 - 1.0 t2 = t1 * 4.0 answer = t0 / t2 return answer
MathQA/1831
python
def problem(): """ having scored 94 runs in the 19 th inning , a cricketer increases his average score by 4 . what will be his average score after 19 innings ? n0 = 94.0 n1 = 19.0 n2 = 4.0 n3 = 19.0 """
having scored 94 runs in the 19 th inning , a cricketer increases his average score by 4 . what will be his average score after 19 innings ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 22.0) def check(x): pass
problem
n0 = 94.0 n1 = 19.0 n2 = 4.0 n3 = 19.0 t0 = n1 * n2 t1 = n0 - t0 answer = n2 + t1 return answer
MathQA/1832
python
def problem(): """ a train 150 m long running at 72 kmph crosses a platform in 25 sec . what is the length of the platform ? n0 = 150.0 n1 = 72.0 n2 = 25.0 """
a train 150 m long running at 72 kmph crosses a platform in 25 sec . what is the length of the platform ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 350.04) def check(x): pass
problem
n0 = 150.0 n1 = 72.0 n2 = 25.0 t0 = n1 * 0.2778 t1 = n2 * t0 answer = t1 - n0 return answer
MathQA/1833
python
def problem(): """ the present worth of a certain bill due sometime hence is rs . 1296 and the true discount is rs . 72 . what is the banker ' s discount ? n0 = 1296.0 n1 = 72.0 """
the present worth of a certain bill due sometime hence is rs . 1296 and the true discount is rs . 72 . what is the banker ' s discount ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 76.0) def check(x): pass
problem
n0 = 1296.0 n1 = 72.0 t0 = n1**min(2.0, 5) t1 = t0 / n0 answer = n1 + t1 return answer
MathQA/1834
python
def problem(): """ a truck covers a distance of 376 km at a certain speed in 8 hours . how much time would a car take at an average speed which is 18 kmph more than that of the speed of the truck to cover a distance which is 14 km more than that travelled by the truck ? n0 = 376.0 n1 = 8.0 n2 = 18.0 n3 = 14.0 """
a truck covers a distance of 376 km at a certain speed in 8 hours . how much time would a car take at an average speed which is 18 kmph more than that of the speed of the truck to cover a distance which is 14 km more than that travelled by the truck ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 6.0) def check(x): pass
problem
n0 = 376.0 n1 = 8.0 n2 = 18.0 n3 = 14.0 t0 = n0 + n3 t1 = n0 / n1 t2 = n2 + t1 answer = t0 / t2 return answer
MathQA/1835
python
def problem(): """ mike took a taxi to the airport and paid $ 2.50 to start plus $ 0.25 per mile . annie took a different route to the airport and paid $ 2.50 plus $ 5.00 in bridge toll fees plus $ 0.25 per mile . if each was charged exactly the same amount , and annie ' s ride was 18 miles , how many miles was mike ' s ride ? n0 = 2.5 n1 = 0.25 n2 = 2.5 n3 = 5.0 n4 = 0.25 n5 = 18.0 """
mike took a taxi to the airport and paid $ 2.50 to start plus $ 0.25 per mile . annie took a different route to the airport and paid $ 2.50 plus $ 5.00 in bridge toll fees plus $ 0.25 per mile . if each was charged exactly the same amount , and annie ' s ride was 18 miles , how many miles was mike ' s ride ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 38.0) def check(x): pass
problem
n0 = 2.5 n1 = 0.25 n2 = 2.5 n3 = 5.0 n4 = 0.25 n5 = 18.0 t0 = n0 + n3 t1 = n1 * n5 t2 = t0 + t1 t3 = t2 - n0 answer = t3 / n1 return answer
MathQA/1836
python
def problem(): """ a mobile battery in 1 hour charges to 20 percent . how much time ( in minute ) will it require more to charge to 55 percent . n0 = 1.0 n1 = 20.0 n2 = 55.0 """
a mobile battery in 1 hour charges to 20 percent . how much time ( in minute ) will it require more to charge to 55 percent .
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 165.0) def check(x): pass
problem
n0 = 1.0 n1 = 20.0 n2 = 55.0 t0 = n2 / n1 answer = t0 * 60.0 return answer
MathQA/1837
python
def problem(): """ in a box of 11 pens , a total of 3 are defective . if a customer buys 2 pens selected at random from the box , what is the probability that neither pen will be defective ? n0 = 11.0 n1 = 3.0 n2 = 2.0 """
in a box of 11 pens , a total of 3 are defective . if a customer buys 2 pens selected at random from the box , what is the probability that neither pen will be defective ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 0.509090909090909) def check(x): pass
problem
n0 = 11.0 n1 = 3.0 n2 = 2.0 t0 = n0 - n1 t1 = n0 - 1.0 t2 = t0 / n0 t3 = t0 - 1.0 t4 = t3 / t1 answer = t2 * t4 return answer
MathQA/1838
python
def problem(): """ a rectangular box measures internally 1.6 m long , 1 m broad and 60 cm deep . the number of cubical box each of edge 20 cm that can be packed inside the box is : n0 = 1.6 n1 = 1.0 n2 = 60.0 n3 = 20.0 """
a rectangular box measures internally 1.6 m long , 1 m broad and 60 cm deep . the number of cubical box each of edge 20 cm that can be packed inside the box is :
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 119.99999999999999) def check(x): pass
problem
n0 = 1.6 n1 = 1.0 n2 = 60.0 n3 = 20.0 t0 = n3 / 100.0 t1 = n2 / 100.0 t2 = n0 / t0 t3 = n1 / t0 t4 = t1 / t0 answer = t2 * t3 * t4 return answer
MathQA/1839
python
def problem(): """ bucket p has thrice the capacity as bucket q . it takes 60 turns for bucket p to fill the empty drum . how many turns it will take for both the buckets p & q , having each turn together to fill the empty drum ? n0 = 60.0 """
bucket p has thrice the capacity as bucket q . it takes 60 turns for bucket p to fill the empty drum . how many turns it will take for both the buckets p & q , having each turn together to fill the empty drum ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 45.0) def check(x): pass
problem
n0 = 60.0 t0 = 1.0 / n0 t1 = n0 * 3.0 t2 = 1.0 / t1 t3 = t0 + t2 answer = 1.0 / t3 return answer
MathQA/1840
python
def problem(): """ a father said his son , ` ` i was as old as you are at present at the time of your birth . ` ` if the father age is 40 now , the son age 5 years back was n0 = 40.0 n1 = 5.0 """
a father said his son , ` ` i was as old as you are at present at the time of your birth . ` ` if the father age is 40 now , the son age 5 years back was
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 15.0) def check(x): pass
problem
n0 = 40.0 n1 = 5.0 t0 = n0 / 2.0 answer = t0 - n1 return answer
MathQA/1841
python
def problem(): """ the h . c . f . of two numbers is 30 and the other two factors of their l . c . m . are 13 and 14 . the larger of the two numbers is : n0 = 30.0 n1 = 13.0 n2 = 14.0 """
the h . c . f . of two numbers is 30 and the other two factors of their l . c . m . are 13 and 14 . the larger of the two numbers is :
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 420.0) def check(x): pass
problem
n0 = 30.0 n1 = 13.0 n2 = 14.0 answer = n0 * n2 return answer
MathQA/1842
python
def problem(): """ find compound interest on rs . 7500 at 4 % per year for 2 years , compounded annually . n0 = 7500.0 n1 = 4.0 n2 = 2.0 """
find compound interest on rs . 7500 at 4 % per year for 2 years , compounded annually .
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 612.0) def check(x): pass
problem
n0 = 7500.0 n1 = 4.0 n2 = 2.0 t0 = n0 * n1 t1 = t0 / 100.0 t2 = n0 + t1 t3 = n1 * t2 t4 = t3 / 100.0 t5 = t2 + t4 answer = t5 - n0 return answer
MathQA/1843
python
def problem(): """ in an election only two candidates contested . a candidate secured 70 % of the valid votes and won by a majority of 178 votes . find the total number of valid votes ? n0 = 70.0 n1 = 178.0 """
in an election only two candidates contested . a candidate secured 70 % of the valid votes and won by a majority of 178 votes . find the total number of valid votes ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 445.0) def check(x): pass
problem
n0 = 70.0 n1 = 178.0 t0 = 100.0 - n0 t1 = n0 - t0 t2 = t1 / 100.0 answer = n1 / t2 return answer
MathQA/1844
python
def problem(): """ 6 computers , each working at the same constant rate , together can process a certain amount of data in 9 days . how many additional computers , each working at the same constant rate , will be needed to process the same amount of data in 6 days ? n0 = 6.0 n1 = 9.0 n2 = 6.0 """
6 computers , each working at the same constant rate , together can process a certain amount of data in 9 days . how many additional computers , each working at the same constant rate , will be needed to process the same amount of data in 6 days ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 3.0) def check(x): pass
problem
n0 = 6.0 n1 = 9.0 n2 = 6.0 t0 = 1.0 / n0 t1 = 1.0 / n1 t2 = n0 * t0 t3 = t2 / t1 answer = t3 - n0 return answer
MathQA/1845
python
def problem(): """ mark bought a set of 6 flower pots of different sizes at a total cost of $ 8.00 . each pot cost 0.25 more than the next one below it in size . what was the cost , in dollars , of the largest pot ? n0 = 6.0 n1 = 8.0 n2 = 0.25 """
mark bought a set of 6 flower pots of different sizes at a total cost of $ 8.00 . each pot cost 0.25 more than the next one below it in size . what was the cost , in dollars , of the largest pot ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 1.9583333333333335) def check(x): pass
problem
n0 = 6.0 n1 = 8.0 n2 = 0.25 t0 = n0 - 1.0 t1 = n0 * t0 t2 = n2 * t0 t3 = t1 / 2.0 t4 = n2 * t3 t5 = n1 - t4 t6 = t5 / n0 answer = t6 + t2 return answer
MathQA/1846
python
def problem(): """ a rectangular grassy plot 110 m by 65 cm has a gravel path . 5 cm wide all round it on the inside . find the cost of gravelling the path at 80 paise per sq . mt n0 = 110.0 n1 = 65.0 n2 = 5.0 n3 = 80.0 """
a rectangular grassy plot 110 m by 65 cm has a gravel path . 5 cm wide all round it on the inside . find the cost of gravelling the path at 80 paise per sq . mt
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 680.0) def check(x): pass
problem
n0 = 110.0 n1 = 65.0 n2 = 5.0 n3 = 80.0 t0 = n3 / 100.0 t1 = n0 * n1 t2 = n0 - n2 t3 = n1 - n2 t4 = t2 * t3 t5 = t1 - t4 answer = t0 * t5 return answer
MathQA/1847
python
def problem(): """ in a dairy farm , 16 cows eat 16 bags of husk in 16 days . in how many days one cow will eat one bag of husk ? n0 = 16.0 n1 = 16.0 n2 = 16.0 """
in a dairy farm , 16 cows eat 16 bags of husk in 16 days . in how many days one cow will eat one bag of husk ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 16.0) def check(x): pass
problem
n0 = 16.0 n1 = 16.0 n2 = 16.0 t0 = n0 / n0 answer = n0 * t0 return answer
MathQA/1848
python
def problem(): """ in 12 pumps can raise 1218 tons of water in 11 days of 9 hrs each , how many pumps will raise 2030 tons of water in 12 days of 11 hrs each ? n0 = 12.0 n1 = 1218.0 n2 = 11.0 n3 = 9.0 n4 = 2030.0 n5 = 12.0 n6 = 11.0 """
in 12 pumps can raise 1218 tons of water in 11 days of 9 hrs each , how many pumps will raise 2030 tons of water in 12 days of 11 hrs each ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 15.0) def check(x): pass
problem
n0 = 12.0 n1 = 1218.0 n2 = 11.0 n3 = 9.0 n4 = 2030.0 n5 = 12.0 n6 = 11.0 t0 = n0 * n2 t1 = n3 * t0 t2 = n1 * t0 t3 = n4 * t1 answer = t3 / t2 return answer
MathQA/1849
python
def problem(): """ 32.32 / 2000 is equal to : n0 = 32.32 n1 = 2000.0 """
32.32 / 2000 is equal to :
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 0.01616) def check(x): pass
problem
n0 = 32.32 n1 = 2000.0 answer = n0 / n1 return answer
MathQA/1850
python
def problem(): """ george went to a fruit market with certain amount of money . with this money he can buy either 50 oranges or 40 mangoes . he retains 5 % of the money for taxi fare and buys 25 mangoes . how many oranges can he buy ? n0 = 50.0 n1 = 40.0 n2 = 5.0 n3 = 25.0 """
george went to a fruit market with certain amount of money . with this money he can buy either 50 oranges or 40 mangoes . he retains 5 % of the money for taxi fare and buys 25 mangoes . how many oranges can he buy ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 22.499999999999996) def check(x): pass
problem
n0 = 50.0 n1 = 40.0 n2 = 5.0 n3 = 25.0 t0 = n2 / 100.0 t1 = n3 / n0 t2 = 1.0 - t0 t3 = t2 - t1 answer = n0 * t3 return answer
MathQA/1851
python
def problem(): """ if 4 spiders make 4 webs in 4 days , then 1 spider will make 1 web in how many days ? n0 = 4.0 n1 = 4.0 n2 = 4.0 n3 = 1.0 n4 = 1.0 """
if 4 spiders make 4 webs in 4 days , then 1 spider will make 1 web in how many days ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 4.0) def check(x): pass
problem
n0 = 4.0 n1 = 4.0 n2 = 4.0 n3 = 1.0 n4 = 1.0 answer = n0 * n3 return answer
MathQA/1852
python
def problem(): """ in an examination , there were 2,000 candidates , out of which 900 candidates were girls and rest were boys . if 36 % of the boys and 32 % of the girls passed , then the total percentage of failed candidates is ? n0 = 2000.0 n1 = 900.0 n2 = 36.0 n3 = 32.0 """
in an examination , there were 2,000 candidates , out of which 900 candidates were girls and rest were boys . if 36 % of the boys and 32 % of the girls passed , then the total percentage of failed candidates is ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 65.8) def check(x): pass
problem
n0 = 2000.0 n1 = 900.0 n2 = 36.0 n3 = 32.0 t0 = n2 / 100.0 t1 = n3 / 100.0 t2 = 10.0 * 100.0 t3 = t2 * 2.0 t4 = n1 * t1 t5 = t3 - n1 t6 = t0 * t5 t7 = t3 - t6 t8 = t7 - t4 t9 = t8 / t3 answer = t9 * 100.0 return answer
MathQA/1853
python
def problem(): """ john left home and drove at the rate of 50 mph for 2 hours . he stopped for lunch then drove for another 3 hours at the rate of 55 mph to reach his destination . how many miles did john drive ? n0 = 50.0 n1 = 2.0 n2 = 3.0 n3 = 55.0 """
john left home and drove at the rate of 50 mph for 2 hours . he stopped for lunch then drove for another 3 hours at the rate of 55 mph to reach his destination . how many miles did john drive ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 265.0) def check(x): pass
problem
n0 = 50.0 n1 = 2.0 n2 = 3.0 n3 = 55.0 t0 = n0 * n1 t1 = n2 * n3 answer = t0 + t1 return answer
MathQA/1854
python
def problem(): """ a boat having a length 3 m and breadth 2 m is floating on a lake . the boat sinks by 1 cm when a man gets on it . the mass of the man is : n0 = 3.0 n1 = 2.0 n2 = 1.0 """
a boat having a length 3 m and breadth 2 m is floating on a lake . the boat sinks by 1 cm when a man gets on it . the mass of the man is :
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 60.0) def check(x): pass
problem
n0 = 3.0 n1 = 2.0 n2 = 1.0 t0 = n2 / 100.0 t1 = n0 * n1 t2 = t0 * t1 answer = t2 * 1000.0 return answer
MathQA/1855
python
def problem(): """ anne earned $ 3 an hour baby - sitting , and $ 4 an hour working in the garden . last week she did baby - sitting for 5 hours and garden work for 3 hours . how much more money does she need to buy a game that costs $ 35 ? n0 = 3.0 n1 = 4.0 n2 = 5.0 n3 = 3.0 n4 = 35.0 """
anne earned $ 3 an hour baby - sitting , and $ 4 an hour working in the garden . last week she did baby - sitting for 5 hours and garden work for 3 hours . how much more money does she need to buy a game that costs $ 35 ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 8.0) def check(x): pass
problem
n0 = 3.0 n1 = 4.0 n2 = 5.0 n3 = 3.0 n4 = 35.0 t0 = n0 * n2 t1 = n0 * n1 t2 = t0 + t1 answer = n4 - t2 return answer
MathQA/1856
python
def problem(): """ if the average ( arithmetic mean ) of a and b is 45 and the average of b and c is 80 , what is the value of c â ˆ ’ a ? n0 = 45.0 n1 = 80.0 """
if the average ( arithmetic mean ) of a and b is 45 and the average of b and c is 80 , what is the value of c â ˆ ’ a ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 70.0) def check(x): pass
problem
n0 = 45.0 n1 = 80.0 t0 = n1 * 2.0 t1 = n0 * 2.0 answer = t0 - t1 return answer
MathQA/1857
python
def problem(): """ a envelop weight 8.2 gm , if 800 of these envelop are sent with an advertisement mail . how much wieght ? n0 = 8.2 n1 = 800.0 """
a envelop weight 8.2 gm , if 800 of these envelop are sent with an advertisement mail . how much wieght ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 6.559999999999999) def check(x): pass
problem
n0 = 8.2 n1 = 800.0 t0 = n0 * n1 answer = t0 / 1000.0 return answer
MathQA/1858
python
def problem(): """ if a coin is flipped , the probability that the coin will land heads is 1 / 2 . if the coin is flipped 5 times , what is the probability that it will land tails up on the first 4 flips and not on the last flip ? n0 = 1.0 n1 = 2.0 n2 = 5.0 n3 = 4.0 """
if a coin is flipped , the probability that the coin will land heads is 1 / 2 . if the coin is flipped 5 times , what is the probability that it will land tails up on the first 4 flips and not on the last flip ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 0.03125) def check(x): pass
problem
n0 = 1.0 n1 = 2.0 n2 = 5.0 n3 = 4.0 t0 = n1**min(n2, 5) answer = 1.0 / t0 return answer
MathQA/1859
python
def problem(): """ the cross - section of a water channel is a trapezium in shape . if the channel is 14 meters wide at the top and 8 meters wide at the bottom and the area of cross - section is 990 square meters , what is the depth of the channel ( in meters ) ? n0 = 14.0 n1 = 8.0 n2 = 990.0 """
the cross - section of a water channel is a trapezium in shape . if the channel is 14 meters wide at the top and 8 meters wide at the bottom and the area of cross - section is 990 square meters , what is the depth of the channel ( in meters ) ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 90.0) def check(x): pass
problem
n0 = 14.0 n1 = 8.0 n2 = 990.0 t0 = n0 + n1 t1 = t0 / 2.0 answer = n2 / t1 return answer
MathQA/1860
python
def problem(): """ income and expenditure of a person are in the ratio 5 : 4 . if the income of the person is rs . 14000 , then find his savings ? n0 = 5.0 n1 = 4.0 n2 = 14000.0 """
income and expenditure of a person are in the ratio 5 : 4 . if the income of the person is rs . 14000 , then find his savings ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 2800.0) def check(x): pass
problem
n0 = 5.0 n1 = 4.0 n2 = 14000.0 t0 = n1 / n0 t1 = n2 * t0 answer = n2 - t1 return answer
MathQA/1861
python
def problem(): """ two employees x and y are paid a total of rs . 750 per week by their employer . if x is paid 120 percent of the sum paid to y , how much is y paid per week ? n0 = 750.0 n1 = 120.0 """
two employees x and y are paid a total of rs . 750 per week by their employer . if x is paid 120 percent of the sum paid to y , how much is y paid per week ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 340.90909090909093) def check(x): pass
problem
n0 = 750.0 n1 = 120.0 t0 = 1.0 + 4.0 t1 = t0 * 2.0 t2 = t1 + 1.0 t3 = n0 * t1 t4 = t2 * 2.0 answer = t3 / t4 return answer
MathQA/1862
python
def problem(): """ the difference between compound interest and simple interest on a certain amount of money at 5 % per annum for 2 years is 19 . find the sum : n0 = 5.0 n1 = 2.0 n2 = 19.0 """
the difference between compound interest and simple interest on a certain amount of money at 5 % per annum for 2 years is 19 . find the sum :
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 7600.000000000162) def check(x): pass
problem
n0 = 5.0 n1 = 2.0 n2 = 19.0 t0 = n0 / 100.0 t1 = t0 + 1.0 t2 = n1 * t0 t3 = t2 + 1.0 t4 = t1**min(n1, 5) t5 = t4 - t3 answer = n2 / t5 return answer
MathQA/1863
python
def problem(): """ machine a produces 100 parts twice as fast as machine b does . machine b produces 100 parts in 60 minutes . if each machine produces parts at a constant rate , how many parts does machine a produce in 6 minutes ? n0 = 100.0 n1 = 100.0 n2 = 60.0 n3 = 6.0 """
machine a produces 100 parts twice as fast as machine b does . machine b produces 100 parts in 60 minutes . if each machine produces parts at a constant rate , how many parts does machine a produce in 6 minutes ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 20.0) def check(x): pass
problem
n0 = 100.0 n1 = 100.0 n2 = 60.0 n3 = 6.0 t0 = n0 / n2 t1 = t0 * 2.0 answer = n3 * t1 return answer
MathQA/1864
python
def problem(): """ if n is a prime number greater than 5 , what is the remainder when n ^ 2 is divided by 12 ? n0 = 5.0 n1 = 2.0 n2 = 12.0 """
if n is a prime number greater than 5 , what is the remainder when n ^ 2 is divided by 12 ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 1.0) def check(x): pass
problem
n0 = 5.0 n1 = 2.0 n2 = 12.0 t0 = n0 + 2.0 t1 = n2 * 4.0 t2 = t0**min(n1, 5) answer = t2 - t1 return answer
MathQA/1865
python
def problem(): """ set j consists of 5 consecutive even numbers . if the smallest term in the set is - 2 , what is the range of the positive integers in set j ? n0 = 5.0 n1 = 2.0 """
set j consists of 5 consecutive even numbers . if the smallest term in the set is - 2 , what is the range of the positive integers in set j ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 4.0) def check(x): pass
problem
n0 = 5.0 n1 = 2.0 t0 = -n1 t1 = n0 - 1.0 t2 = n1 * t1 t3 = t2 + t0 answer = t3 - n1 return answer
MathQA/1866
python
def problem(): """ a student chose a number , multiplied it by 2 , then subtracted 180 from the result and got 104 . what was the number he chose ? n0 = 2.0 n1 = 180.0 n2 = 104.0 """
a student chose a number , multiplied it by 2 , then subtracted 180 from the result and got 104 . what was the number he chose ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 142.0) def check(x): pass
problem
n0 = 2.0 n1 = 180.0 n2 = 104.0 t0 = n1 + n2 answer = t0 / n0 return answer
MathQA/1867
python
def problem(): """ the pinedale bus line travels at an average speed of 60 km / h , and has stops every 5 minutes along its route . yahya wants to go from his house to the pinedale mall , which is 9 stops away . how far away , in kilometers , is pinedale mall away from yahya ' s house ? n0 = 60.0 n1 = 5.0 n2 = 9.0 """
the pinedale bus line travels at an average speed of 60 km / h , and has stops every 5 minutes along its route . yahya wants to go from his house to the pinedale mall , which is 9 stops away . how far away , in kilometers , is pinedale mall away from yahya ' s house ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 45.0) def check(x): pass
problem
n0 = 60.0 n1 = 5.0 n2 = 9.0 t0 = n1 * n2 t1 = t0 / n0 answer = n0 * t1 return answer
MathQA/1868
python
def problem(): """ in a certain warehouse , 50 percent of the packages weigh less than 75 pounds , and a total of 48 packages weigh less than 25 pounds . if 80 percent of the packages weigh at least 25 pounds , how many of the packages weigh at least 25 pounds but less than 75 pounds ? n0 = 50.0 n1 = 75.0 n2 = 48.0 n3 = 25.0 n4 = 80.0 n5 = 25.0 n6 = 25.0 n7 = 75.0 """
in a certain warehouse , 50 percent of the packages weigh less than 75 pounds , and a total of 48 packages weigh less than 25 pounds . if 80 percent of the packages weigh at least 25 pounds , how many of the packages weigh at least 25 pounds but less than 75 pounds ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 72.0) def check(x): pass
problem
n0 = 50.0 n1 = 75.0 n2 = 48.0 n3 = 25.0 n4 = 80.0 n5 = 25.0 n6 = 25.0 n7 = 75.0 t0 = 100.0 - n4 t1 = n2 / t0 t2 = t1 * 100.0 t3 = n0 * t2 t4 = t3 / 100.0 answer = t4 - n2 return answer
MathQA/1869
python
def problem(): """ in one hour , a boat goes 11 km along the stream and 5 km against the stream . the speed of the boat in still water ( in km / hr ) is : n0 = 11.0 n1 = 5.0 """
in one hour , a boat goes 11 km along the stream and 5 km against the stream . the speed of the boat in still water ( in km / hr ) is :
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 8.0) def check(x): pass
problem
n0 = 11.0 n1 = 5.0 t0 = n0 + n1 answer = t0 / 2.0 return answer
MathQA/1870
python
def problem(): """ the ratio of the cost price and the selling price is 4 : 5 . the profit percent is ? n0 = 4.0 n1 = 5.0 """
the ratio of the cost price and the selling price is 4 : 5 . the profit percent is ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 25.0) def check(x): pass
problem
n0 = 4.0 n1 = 5.0 t0 = n1 / n0 t1 = t0 - 1.0 answer = t1 * 100.0 return answer
MathQA/1871
python
def problem(): """ if 45 % of a class averages 100 % on a test , 50 % of the class averages 78 % on the test , and the remainder of the class averages 65 % on the test , what is the overall class average ? ( round final answer to the nearest percent ) . n0 = 45.0 n1 = 100.0 n2 = 50.0 n3 = 78.0 n4 = 65.0 """
if 45 % of a class averages 100 % on a test , 50 % of the class averages 78 % on the test , and the remainder of the class averages 65 % on the test , what is the overall class average ? ( round final answer to the nearest percent ) .
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 87.25) def check(x): pass
problem
n0 = 45.0 n1 = 100.0 n2 = 50.0 n3 = 78.0 n4 = 65.0 t0 = n0 + n2 t1 = n0 * n1 t2 = n2 * n3 t3 = t1 + t2 t4 = 100.0 - t0 t5 = n4 * t4 t6 = t3 + t5 answer = t6 / 100.0 return answer
MathQA/1872
python
def problem(): """ of the votes cast on a certain proposal , 62 more were in favor of the proposal than were against it . if the number of votes against the proposal was 40 percent of the total vote , what was the total number of votes cast ? ( each vote cast was either in favor of the proposal or against it . ) n0 = 62.0 n1 = 40.0 """
of the votes cast on a certain proposal , 62 more were in favor of the proposal than were against it . if the number of votes against the proposal was 40 percent of the total vote , what was the total number of votes cast ? ( each vote cast was either in favor of the proposal or against it . )
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 310.00000000000006) def check(x): pass
problem
n0 = 62.0 n1 = 40.0 t0 = n1 / 100.0 t1 = 1.0 - t0 t2 = t1 - t0 answer = n0 / t2 return answer
MathQA/1873
python
def problem(): """ how many of the integers between 20 and 80 are even ? n0 = 20.0 n1 = 80.0 """
how many of the integers between 20 and 80 are even ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 30.0) def check(x): pass
problem
n0 = 20.0 n1 = 80.0 t0 = n1 - n0 answer = t0 / 2.0 return answer
MathQA/1874
python
def problem(): """ if a and b are positive integers , and a = 5 b + 20 , the greatest common divisor of a and b can not be n0 = 5.0 n1 = 20.0 """
if a and b are positive integers , and a = 5 b + 20 , the greatest common divisor of a and b can not be
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 6.0) def check(x): pass
problem
n0 = 5.0 n1 = 20.0 t0 = n1 / n0 answer = t0 + 2.0 return answer
MathQA/1875
python
def problem(): """ express 35 mps in kmph ? n0 = 35.0 """
express 35 mps in kmph ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 126.00000000000001) def check(x): pass
problem
n0 = 35.0 t0 = n0 / 1000.0 answer = t0 * 3600.0 return answer
MathQA/1876
python
def problem(): """ the area of a square field 3136 sq m , if the length of cost of drawing barbed wire 3 m around the field at the rate of rs . 2.50 per meter . two gates of 1 m width each are to be left for entrance . what is the total cost ? n0 = 3136.0 n1 = 3.0 n2 = 2.5 n3 = 1.0 """
the area of a square field 3136 sq m , if the length of cost of drawing barbed wire 3 m around the field at the rate of rs . 2.50 per meter . two gates of 1 m width each are to be left for entrance . what is the total cost ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 1665.0) def check(x): pass
problem
import math n0 = 3136.0 n1 = 3.0 n2 = 2.5 n3 = 1.0 t0 = n3 * 2.0 t1 = math.sqrt(max(0, n0)) t2 = t1 * 4.0 t3 = t2 - t0 t4 = n2 * t3 answer = t4 * n1 return answer
MathQA/1877
python
def problem(): """ there are 690 male and female participants in a meeting . half the female participants and one - quarter of the male participants are democrats . one - third of all the participants are democrats . how many of the democrats are female ? n0 = 690.0 """
there are 690 male and female participants in a meeting . half the female participants and one - quarter of the male participants are democrats . one - third of all the participants are democrats . how many of the democrats are female ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 115.0) def check(x): pass
problem
n0 = 690.0 t0 = n0 / 3.0 t1 = t0 * 4.0 t2 = t1 - n0 answer = t2 / 2.0 return answer
MathQA/1878
python
def problem(): """ find the area of a parallelogram with base 20 cm and height 40 cm ? n0 = 20.0 n1 = 40.0 """
find the area of a parallelogram with base 20 cm and height 40 cm ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 800.0) def check(x): pass
problem
n0 = 20.0 n1 = 40.0 answer = n0 * n1 return answer
MathQA/1879
python
def problem(): """ a can do a piece of work in 6 hours ; b and c together can do it in 4 hours , which a and c together can do it in 3 hours . how long will b alone take to do it ? n0 = 6.0 n1 = 4.0 n2 = 3.0 """
a can do a piece of work in 6 hours ; b and c together can do it in 4 hours , which a and c together can do it in 3 hours . how long will b alone take to do it ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 11.999999999999998) def check(x): pass
problem
n0 = 6.0 n1 = 4.0 n2 = 3.0 t0 = 1.0 / n1 t1 = 1.0 / n2 t2 = 1.0 / n0 t3 = t1 - t2 t4 = t0 - t3 answer = 1.0 / t4 return answer
MathQA/1880
python
def problem(): """ a train 250 m long running at 72 kmph crosses a platform in 30 sec . what is the length of the platform ? n0 = 250.0 n1 = 72.0 n2 = 30.0 """
a train 250 m long running at 72 kmph crosses a platform in 30 sec . what is the length of the platform ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 350.048) def check(x): pass
problem
n0 = 250.0 n1 = 72.0 n2 = 30.0 t0 = n1 * 0.2778 t1 = n2 * t0 answer = t1 - n0 return answer
MathQA/1881
python
def problem(): """ 4 shepherds were watching over the flocks and they were commenting on how many sheep they each had . if ram had 3 more sheep than he would have one less than rahul . wheras akar has the same number as the other 3 shepherds put togeher . if john had 3 less sheep he would have exactly trile the number of ram . if they were evenly distributed if they would each have 11 seep how many sheep did ram have ? n0 = 4.0 n1 = 3.0 n2 = 3.0 n3 = 3.0 n4 = 11.0 """
4 shepherds were watching over the flocks and they were commenting on how many sheep they each had . if ram had 3 more sheep than he would have one less than rahul . wheras akar has the same number as the other 3 shepherds put togeher . if john had 3 less sheep he would have exactly trile the number of ram . if they were evenly distributed if they would each have 11 seep how many sheep did ram have ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 3.0) def check(x): pass
problem
n0 = 4.0 n1 = 3.0 n2 = 3.0 n3 = 3.0 n4 = 11.0 t0 = n0 + n1 t1 = n0 + 1.0 t2 = n4 * 2.0 t3 = t2 - t0 answer = t3 / t1 return answer
MathQA/1882
python
def problem(): """ a shopkeeper sold an article offering a discount of 5 % and earned a profit of 31.1 % . what would have been the percentage of profit earned if no discount had been offered ? n0 = 5.0 n1 = 31.1 """
a shopkeeper sold an article offering a discount of 5 % and earned a profit of 31.1 % . what would have been the percentage of profit earned if no discount had been offered ?
import math def compare(x, y): return math.fabs(x-y)<1e-8 candidate = problem assert compare(candidate(), 38.0) def check(x): pass
problem
n0 = 5.0 n1 = 31.1 t0 = n1 + 100.0 t1 = 100.0 - n0 t2 = t0 * 100.0 t3 = t2 / t1 answer = t3 - 100.0 return answer