question stringlengths 11 2.89k | code stringlengths 20 7.24k |
|---|---|
Leo wants to buy a skateboard that costs $80. He has already saved $35 from his allowance. He earns $5 for each hour he works at his neighbor's garden. How many hours does Leo need to work to buy the skateboard? | def solve() -> int:
skateboard_cost = 80
amount_saved = 35
hourly_rate = 5
amount_needed = skateboard_cost - amount_saved
hours_needed = amount_needed / hourly_rate
result = hours_needed
return result
|
Lucy is baking cookies. The recipe says to use 2 tablespoons of sugar for each cookie. In a bag of sugar, there are 4 cups. In one cup of sugar there are 96 tablespoons. How many bags of sugar should Lucy buy to make 3 dozen cookies? | def solve() -> int:
bags_of_sugar = 3*36*2/96/4
result = bags_of_sugar
return result
|
If Eric's average score in six tests is 90 and he got a score of 88 in his last test, what was his average score in the first five tests? | def solve() -> int:
total_score = 90 * 6
last_test_score = 88
total_score_before_last_test = total_score - last_test_score
average_score_first_five_tests = total_score_before_last_test / 5
result = average_score_first_five_tests
return result
|
An apple costs $0.50. A customer buys 3 apples and pays $2.00. How much change should the customer receive back? | def solve() -> int:
apple_cost = 0.50
num_apples = 3
total_cost = 2.00
change = total_cost - (apple_cost * num_apples)
result = change
return result
|
A construction company has 20 workers and can complete a project in 10 days. If a client needs the project to be finished in 5 days, how many more workers will the company need to hire? | def solve() -> int:
workers = 20
days = 10
required_days = 5
total_work = workers * days
work_done = total_work * (required_days / days)
remaining_work = total_work - work_done
additional_workers = remaining_work / required_days
result = additional_workers
re... |
Student: A company has 450 employees. 2/5 of the employees are women, and 3/8 of the women are managers. If there are 60 female managers, how many male employees are there in the company? | def solve() -> int:
total_employees = 450
female_employees = 2/5 * total_employees
female_managers = 3/8 * female_employees
male_employees = total_employees - female_employees
result = male_employees - female_managers
return result
|
Jenny earned $9 an hour working a part-time job. She worked 25 hours last week and spent $30 on gas. How much did she keep in her pocket? | def solve() -> int:
hourly_rate = 9
hours_worked = 25
gas_expense = 30
total_earned = hourly_rate * hours_worked
total_expense = gas_expense
amount_kept = total_earned - total_expense
result = amount_kept
return result
|
The temperature in Dallas is 20 degrees colder than in Miami, and the temperature in Miami is 10 degrees warmer than in Los Angeles. If the temperature in Dallas is 50 degrees, what is the temperature in Los Angeles in degrees? | def solve() -> int:
dallas_temp = 50
miami_temp = dallas_temp + 20
LA_temp = miami_temp - 10
result = LA_temp
return result
|
Tania had 60 marbles. She gave away 3/8 of them and 130 more marbles were added. How many marbles does she have now? | def solve() -> int:
total = 60
total = total - (3/8 * total)
total = total + 130
result = total
return result
|
7. During a holiday sale, a store has 32 items on sale with each item having 10% off its original price. If the original price for each item is $20, how much money will the store make in total from the sale? | def solve() -> int:
num_items = 32
original_price = 20
percent_off = 0.1
total_price = num_items * (original_price * (1 - percent_off))
result = total_price
return result
|
The perimeter of a rectangular garden is 42 meters. The length is 3 meters less than twice the width. If the width is 6 meters, calculate the length of the garden. | def solve() -> int:
width = 6
perimeter = 42
length = (perimeter/2) - 3 - width
result = length
return result
|
Student: Eva reads 8 books every month. Frank reads 1/4 as many books as Eva every month. Grace reads 3/8 of the total of what Eva and Frank read every month. If Harry reads twice as many books as Grace does, how many books do they all read in a month? | def solve() -> int:
eva_books = 8
frank_books = eva_books / 4
total_books = eva_books + frank_books
grace_books = 3/8 * total_books
harry_books = 2 * grace_books
total_read = eva_books + frank_books + grace_books + harry_books
result = total_read
return result
|
Amy had 7 candies and 3 cookies. She ate 2 candies and 1 cookie. Then she found 5 more candies and 2 more cookies in her backpack. How many candies and cookies does Amy have now? | def solve() -> int:
candies = 7
cookies = 3
candies = candies - 2
cookies = cookies - 1
candies = candies + 5
cookies = cookies + 2
result = (candies, cookies)
return result
|
Jackson buys a laptop for $1000, which is 12% less than what Chloe paid for the same laptop. How much did Chloe pay for her laptop? | def solve() -> int:
x = 1000 / 0.88
result = x
return result
|
Student: Jane has 40 stickers. On Mondays, Wednesdays and Fridays, she pastes 3 stickers and on the rest of the days of the week, she pastes 2 stickers every day. How many weeks will it take for Jane to paste all of her stickers? | def solve() -> int:
stickers = 40
mwf = 3
other = 2
total_per_week = mwf * 3 + other * 4
weeks = stickers // total_per_week
remaining = stickers % total_per_week
days = weeks * 7 + remaining // mwf + remaining // other
result = weeks + days // 7
return result
|
Lily, Ivy, and Rose have a shared flower arrangement collection. A rare flower arrangement is being sold by a friend for $180 on her website. They have collected all their money to buy the flower arrangement. Rose has $5, while Ivy has 3 times the money that Lily has and half of Rose’s sum. How much more money do they ... | def solve() -> int:
rose_money = 5
lily_money = 0
ivy_money = 0
ivy_money = (1/2) * rose_money
lily_money = (ivy_money / 3)
total_money = rose_money + ivy_money + lily_money
difference = 180 - total_money
result = difference
return result
|
A car travels at a speed of 60 km/hour. How far will the car travel in 2 hours? | def solve() -> int:
speed = 60
time = 2
distance = speed * time
result = distance
return result
|
Jackson needs to make $150 to buy a new guitar. He convinces his grandparents to pay him for doing extra work around the house. Normally, he does 10 chores a week. His grandparents agree to pay him $3 for every extra chore he does during the week. If he does 5 extra chores every other day for 4 weeks, how much does he ... | def solve() -> int:
total_chores_per_week = 10
extra_chores_per_day = 5
extra_chores_per_week = extra_chores_per_day * 4
total_chores = total_chores_per_week * 4 + extra_chores_per_week
amount_earned = total_chores * 3
result = amount_earned
return result
|
There are 24 kids in a classroom. If the ratio of boys to girls is 2:3, how many boys are in the classroom? | def solve() -> int:
total_students = 24
boy_to_girl_ratio = 2/3
num_boys = total_students * boy_to_girl_ratio
result = num_boys
return result
|
After a busy week of work, Will went on a weekend vacation. He left with 200$, but spent 75$ on gas for his car, 25$ on food and drinks and 50$ on hotel accommodation. How much money does Will have left? | def solve() -> int:
x = 200
x = x - 75
x = x - 25
x = x - 50
result = x
return result
|
In a shooting competition, Jack and Jill had to shoot at a target 10 times each. Jack hit the target 9 times and Jill hit it 7 times. What was the difference in their hit percentage? | def solve() -> int:
jack_hits = 9
jill_hits = 7
jack_total_shots = 10
jill_total_shots = 10
jack_hit_percentage = (jack_hits / jack_total_shots) * 100
jill_hit_percentage = (jill_hits / jill_total_shots) * 100
difference_in_hit_percentage = jack_hit_percentage - jill_hit_perce... |
arah has 108 brushes that can each hold 10ml of paint. How much paint can her brushes hold in total? | def solve() -> int:
brushes = 108
capacity = 10
total = brushes * capacity
result = total
return result
|
Possible math questions: Jason took a bus to visit his grandparents, who live 20 miles away from his house. The bus fare was $1.5 for the first mile, and $0.2 for every additional mile. How much did Jason pay for the bus ride? | def solve() -> int:
additional_miles = 20 - 1
additional_cost = 0.2 * additional_miles
total_cost = 1.5 + additional_cost
result = total_cost
return result
|
To make a 50-piece jigsaw puzzle, Olivia needs to use green and blue pieces in the ratio of 4:5. If she used 16 green pieces, how many blue pieces does she need? | def solve() -> int:
green_pieces = 16
blue_pieces = (green_pieces * 5) / 4
result = blue_pieces
return result
|
Alex bought 24 erasers and only 10% of them are white. How many white erasers does Alex have? | def solve() -> int:
erasers = 24
percentage_white = 0.1
white_erasers = erasers * percentage_white
result = white_erasers
return result
|
You have a rectangular room that is 8 feet long and 10 feet wide. You want to buy a rug that covers 80% of the floor. What is the area of the rug you need to buy? | def solve() -> int:
length = 8
width = 10
coverage_percent = 0.8
floor_area = length*width
rug_area = floor_area*coverage_percent
result = rug_area
return result
|
Emma has been saving her spare change in a jar for 2 years. When she checked it, she found she had a total of $70. If she doubled the amount of change she put in the jar each year after the first, and put in the same amount of change the first and second year, how much change did she put in the jar the first year? | def solve() -> int:
x = 70/3
result = x
return result
|
Mark's basketball team played 30 games this season. Their win-loss record is 20-10. What is the percentage of games that Mark's team won this season? | def solve() -> int:
total_games = 30
games_won = 20
win_percentage = games_won / total_games * 100
result = win_percentage
return result
|
Student: Emma buys a shirt for $22.50 and a pair of pants for $36.75. If the sales tax is 8.5%, how much does Emma pay in total? | def solve() -> int:
shirt_price = 22.50
pants_price = 36.75
total_price_before_tax = shirt_price + pants_price
sales_tax = total_price_before_tax * 0.085
total_price_after_tax = total_price_before_tax + sales_tax
result = total_price_after_tax
return result
|
In a factory, each type of toy had to go through a series of tests. Today, out of the 32 toys tested, 2 failed the test and the rest passed. How many toys passed the test? | def solve() -> int:
totalToysTested = 32
failedToys = 2
result = totalToysTested - failedToys
return result
|
ven had 156 erasers. He used 1/3 of them and gave 2/5 of the remainder to his classmate. How many erasers did Steven give to his classmate? | def solve() -> int:
total_erasers = 156
stevens_share = total_erasers * 1 / 3
remaining_erasers = total_erasers - stevens_share
classmates_share = remaining_erasers * 2 / 5
result = classmates_share
return result
|
A factory needs to increase its production by 50% to meet demand. If they are currently producing 1000 units per day, how many more units do they need to produce? | def solve() -> int:
current_production = 1000
increase_percentage = 50
increase_amount = current_production * (increase_percentage / 100)
result = increase_amount
return result
|
The sum of three consecutive integers is 51. What are the three integers? | def solve() -> int:
x = 16
y = x+1
z = y+1
sum_of_integers = x+y+z
result = (x,y,z)
return result
|
Lucas has 180 marbles. He gives away 1/3 of his marbles to his friends Kylie and Mason, who share the marbles in a ratio of 5:2. How many marbles does Kylie get? | def solve() -> int:
marbles = 180
given_away = marbles / 3
kylie_share = given_away * (5 / 7)
result = kylie_share
return result
|
Amy has 24 books. She reads 4 books every week. How many books will she read in 6 weeks? | def solve() -> int:
total_books = 24
books_read = 4
weeks = 6
books_in_6_weeks = books_read * weeks
result = books_in_6_weeks
return result
|
A recipe calls for 2/3 cups of flour. If Jolie wants to triple the recipe, how many cups of flour does she need to use? | def solve() -> int:
flour_needed = 2/3
recipe_multiplier = 3
total_flour_needed = flour_needed * recipe_multiplier
result = f'<<<{total_flour_needed} cups>>>'
result = total_flour_needed
return result
|
A recipe requires 2 1/4 cups of flour to make 24 waffles. If Alex wants to make 36 waffles, how many cups of flour does he need? | def solve() -> int:
n = 36/24
cups_of_flour = 2.25*n
result = cups_of_flour
return result
|
Paul has a poster that measures 20 inches by 30 inches and his sister, Olivia, has a poster that measures 18 inches by 24 inches. If the posters weigh 2.5 oz per square inch of paper space, how much more does Paul's poster weigh in pounds? | def solve() -> int:
paul_length = 20
paul_width = 30
olivia_length = 18
olivia_width = 24
weight_per_square_inch = 2.5
paul_area = paul_length * paul_width
olivia_area = olivia_length * olivia_width
paul_weight = paul_area * weight_per_square_inch
olivia_weight = olivia_are... |
Tom buys a dozen pencils for $1.5 and sells them for $0.5 each. What is his profit after selling them all? | def solve() -> int:
num_pencils = 12
cost_per_pencil = 1.5
sell_per_pencil = 0.5
total_cost = num_pencils * cost_per_pencil
total_sell = num_pencils * sell_per_pencil
profit = total_sell - total_cost
result = profit
return result
|
Jack is distributing a box of chocolates to his friends. He wants to keep 1/4 of them for himself, give half of them away, and save the rest for his family. If he has 48 chocolates in the box, how many will he give away? | def solve() -> int:
box_of_chocolates = 48
jack_share = box_of_chocolates / 4
remaining_chocolates = box_of_chocolates - jack_share
give_away_chocolates = remaining_chocolates / 2
result = give_away_chocolates
return result
|
Student: In a school, there are 624 students and the gender ratio is 3:2 (boys to girls). How many boys are there in the school? | def solve() -> int:
total_students = 624
boy_to_girl_ratio = 3/2
num_boys = total_students * (boy_to_girl_ratio / (boy_to_girl_ratio + 1))
result = round(num_boys)
return result
|
Abby, Alex and Andy have 420 books total. Abby has 7 times as many books as Alex, and Alex has half the number of books that Andy has. How many books does Abby have? | def solve() -> int:
result = 294
return result
|
Student: Kevin has 10 candies. He gives two of them to his brother and then eats three. How many candies does he have left? | def solve() -> int:
candies = 10
brother_candies = 2
eaten_candies = 3
candies -= brother_candies
candies -= eaten_candies
result = candies
return result
|
Jane bought a bike for $1200 with a depreciation rate of 10% per year. How much will it be worth after 5 years? | def solve() -> int:
principal = 1200
depreciation_rate = 0.1
years = 5
final_value = principal * ((1 - depreciation_rate) ** years)
result = final_value
return result
|
Student: If 450 meters of wire can fence a square garden, what is the length of each side of the garden? | def solve() -> int:
length_of_wire = 450
result = length_of_wire / 4
return result
|
A baker makes 50 loaves of bread a day. If she wants to make 300 loaves of bread, how many days will it take her? | def solve() -> int:
daily_bread_production = 50
total_bread_needed = 300
days_needed = total_bread_needed / daily_bread_production
result = days_needed
return result
|
Haley is running a marathon. She has already run 14 miles. The race is 26 miles total. She needs to know what percentage of the race she has already completed. | def solve() -> int:
race_distance = 26
distance_completed = 14
percentage_completed = (distance_completed / race_distance) * 100
result = percentage_completed
return result
|
Lisa bought 8 boxes of chocolates for $12 each and 6 boxes of cookies for $10 each. She sold 5 boxes of chocolates for $15 each and 4 boxes of cookies for $12 each. How much profit or loss did she make? | def solve() -> int:
chocolates_buy = 8
chocolates_sell = 5
chocolates_cost = 12
chocolates_price = 15
cookies_buy = 6
cookies_sell = 4
cookies_cost = 10
cookies_price = 12
cost = chocolates_buy * chocolates_cost + cookies_buy * cookies_cost
revenue = chocolates_sell * chocol... |
Student: If it takes 4 eggs to make a cake and Susan has 16 eggs, how many cakes can she make? | def solve() -> int:
eggs = 16
eggs_per_cake = 4
cakes = eggs // eggs_per_cake
result = cakes
return result
|
Anna has 400 coins consisting of quarters and dimes with total value $70. How many of each coin does Anna have? | def solve() -> int:
coins = 400
value = 70
for quarters in range(1, coins):
dimes = coins - quarters
if quarters * 0.25 + dimes * 0.10 == value:
result = quarters, dimes
return result
|
Student: A square has a perimeter of 20 cm. What is the length of each side? | def solve() -> int:
perimeter = 20
side_length = perimeter / 4
result = side_length
return result
|
A hotel has 150 rooms. If 90 rooms are occupied and 3/10 of the empty rooms are being cleaned, how many rooms are still available for new guests? | def solve() -> int:
total_rooms = 150
occupied_rooms = 90
empty_rooms = total_rooms - occupied_rooms
cleaning_rooms = (3/10) * empty_rooms
available_rooms = empty_rooms - cleaning_rooms
result = available_rooms
return result
|
``` A company has 28 employees, including 20 men and 8 women. If the average salary of all employees is $70,000 and the average salary of the men is $80,000, what is the average salary of the women? | def solve() -> int:
avg_sal_all = 70000
avg_sal_men = 80000
total_sal_men = avg_sal_men * 20
total_sal_all = avg_sal_all * 28
total_sal_women = total_sal_all - total_sal_men
num_women = 8
avg_sal_women = total_sal_women / num_women
result = f'The average salary of the women employees is ... |
A pizza has 8 slices and each slice has 200 calories. Sam ate 3 slices and gave 2 slices to his friend. How many calories did Sam consume and how many calories are left in the pizza? | def solve() -> int:
sam_calories = 3 * 200
slices_left = 8 - (3 + 2)
pizza_calories = slices_left * 200
result = (sam_calories, pizza_calories)
return result
|
A hotel charges $120 per night for a room. If a customer stays for 5 nights, they get a 10% discount. What is the total cost for a 5-night stay? | def solve() -> int:
nightly_rate = 120
stays_in_discount = 5
regular_price = nightly_rate * stays_in_discount
discounted_price = regular_price * 0.9
result = discounted_price
return result
|
A bus company charges $50 per hour to rent a minibus. If a group rents a minibus for 8 hours, how much will they have to pay in total? | def solve() -> int:
hourly_rental_rate = 50
hours_rented = 8
total_cost = hourly_rental_rate * hours_rented
result = total_cost
return result
|
A train travels at a speed of 40 mph. How long does it take to travel a distance of 120 miles? | def solve() -> int:
time = 120 / 40
result = time
return result
|
Angela went to the zoo and counted 5 horses and 7 goats. How many animals did Angela see in total? | def solve() -> int:
horses = 5
goats = 7
result = horses + goats
result = 12
return result
|
Sarah drove for 2 hours at 60mph, and then for another hour at 50mph. How far did she travel? | def solve() -> int:
speed1 = 60
time1 = 2
distance1 = speed1 * time1
speed2 = 50
time2 = 1
distance2 = speed2 * time2
total_distance = distance1 + distance2
result = total_distance
return result
|
An ice cream shop needs to fill orders for the weekend. They need to create 40 cones with 1 scoop of ice cream, 54 cups with 2 scoops of ice cream, and 30 sundaes with 3 scoops of ice cream. Each scoop of ice cream takes 1 ounce of ingredients. How many ounces of ingredients does the shop need for the weekend? | def solve() -> int:
cone_ounces = 40 * 1
cup_ounces = 54 * 2
sundae_ounces = 30 * 3
total_ounces = cone_ounces + cup_ounces + sundae_ounces
result = total_ounces
return result
|
A pizza shop sells small pizzas for $8 each and large pizzas for $12 each. It also charges a delivery fee of $5 per order. If Alice orders 3 small pizzas and 2 large pizzas, how much does she pay in total? | def solve() -> int:
cost_per_small_pizza = 8
cost_per_large_pizza = 12
delivery_fee = 5
number_of_small_pizzas = 3
number_of_large_pizzas = 2
total_cost = cost_per_small_pizza * number_of_small_pizzas + cost_per_large_pizza * number_of_large_pizzas + delivery_fee
result = total_cost
... |
A bakery uses 4 eggs to make a cake, and 1 egg to make 6 cookies. If the bakery wants to make 24 cookies, how many cakes should they make? | def solve() -> int:
eggs_per_cake = 4
eggs_per_cookie = 1/6
num_cookies_desired = 24
num_eggs_needed = num_cookies_desired * eggs_per_cookie
num_cakes_needed = num_eggs_needed / eggs_per_cake
result = num_cakes_needed
return result
|
Jacob studies for 1 hour every afternoon and 2 hours every evening for a month. How many hours does he spend studying in total? | def solve() -> int:
afternoon_hours = 1
evening_hours = 2
days_in_month = 30
total_hours = afternoon_hours + evening_hours
total_hours *= days_in_month
result = total_hours
return result
|
In a theater, there are 10 identical halls. Each hall has 100 seats, 2 projectors, and 5 microphones. If the theater is at 75% of its maximum occupancy, how many people are in the theater? | def solve() -> int:
total_halls = 10
seats_per_hall = 100
projectors_per_hall = 2
microphones_per_hall = 5
maximum_occupancy_percentage = 75
maximum_occupancy = total_halls * seats_per_hall
people_in_theater = maximum_occupancy * maximum_occupancy_percentage / 100
result =... |
Emma bought twice as many bottles of milk as boxes of cereal. If the total number of bottles and boxes was 17, how many boxes of cereal did Emma buy? | def solve() -> int:
total_num = 17
num_bottles = total_num / 3
num_boxes = num_bottles * 2
result = num_boxes
return result
|
Olivia has a washing machine, a microwave in her apartment, and a juicer that consumes power at different rates. The total amount of money that Olivia pays for the energy used by the washing machine is four times the amount she pays for the power used by the microwave. If the electric juicer uses power worth $900 in a ... | def solve() -> int:
juicer_power = 900
microwave_power = juicer_power / 4
washing_machine_power = 4 * microwave_power
total_power_cost = juicer_power + microwave_power + washing_machine_power
result = total_power_cost
return result
|
David collects 20 stamps every month. He has 80 stamps at the beginning of the year. How many stamps does he have at the end of the year? | def solve() -> int:
stamps_per_month = 20
stamps = 80
months = 12
stamps_in_a_year = stamps_per_month * months
stamps += stamps_in_a_year
result = stamps
return result
|
Tom has a budget of $350 for his monthly expenses. If he has already spent $235, what percentage of his budget has he spent? | def solve() -> int:
budget = 350
expenses = 235
spent_percent = expenses / budget * 100
result = f'{spent_percent}%'
result = spent_percent
return result
|
A bakery has to make 200 cakes in a day. They have 50 kg of flour and use 250 grams of flour for each cake. How much flour will be left unused at the end of the day? | def solve() -> int:
flour_for_1_cake = 0.25
flour_for_200_cakes = 200 * flour_for_1_cake
flour_left = 50 - flour_for_200_cakes
result = flour_left
return result
|
Max earns $7.50 per hour babysitting and works for 4 hours. How much money does Max make for babysitting in a week if he works 8 hours per day for 5 days? | def solve() -> int:
wage = 7.50
hourly_work = 4
daily_work = 8
days = 5
total_hours = hourly_work * days + daily_work * (days - 1)
result = total_hours * wage
return result
|
A square has a perimeter of 16 centimeters. What is the area of the square? | def solve() -> int:
perimeter = 16
side_length = perimeter / 4
area = side_length ** 2
result = area
return result
|
Jim drove his car for 25 miles at a speed of 30 mph. How long did it take him? | def solve() -> int:
distance = 25
speed = 30
time = distance / speed
result = time
return result
|
Noah likes to paint pictures for his family, and he can paint one picture in 45 minutes. However, when his cousin Zoe joins him, they can paint one picture in 30 minutes, because they share the paint and brushes. If Noah and Zoe paint together for 90 minutes, and then Noah paints for another 45 minutes by himself, how ... | def solve() -> int:
pictures_with_zoe = 1 * 90 / 30
pictures_by_himself = 1 * 45 / 45
total_pictures = pictures_with_zoe + pictures_by_himself
result = total_pictures
return result
|
Two trains set off from different stations towards the same destination, with the first train arriving at the destination in 4 hours, while the second train arrived 30 minutes later. Assuming both trains traveled at a constant speed, what was the difference in speed, in miles per hour, between the two trains? | def solve() -> int:
d = 1
speed1 = d / 4
speed2 = d / 4.5
difference = speed1 - speed2
result = difference * 60
return result
|
The value of a car depreciates by 8% each year. If a car is initially worth $20,000, what is its value after 5 years? | def solve() -> int:
initial_value = 20000
depreciation_percent = 0.08
time = 5
new_value = initial_value * (1 - depreciation_percent)**time
result = new_value
return result
|
Anna and her sister bought two bags of candy for Halloween. The first bag had 20 pieces of candy and the second bag had 25 pieces of candy. Each piece of candy in the first bag had 10 grams of sugar and each piece of candy in the second bag had 12 grams of sugar. Anna and her sister ate all the candy in the first bag a... | def solve() -> int:
pieces_first_bag = 20
pieces_second_bag = 15
sugar_first_bag = pieces_first_bag * 10
sugar_second_bag = pieces_second_bag * 12
total_sugar = sugar_first_bag + sugar_second_bag
result = total_sugar
return result
|
Student: A shopkeeper bought 36 packets of candies which each packet weighing 500 gram. How much total weight did he buy? | def solve() -> int:
packets = 36
weight_per_packet = 500
total_weight = packets * weight_per_packet
result = total_weight
return result
|
A bakery sells 600 cupcakes in a week. They sell them in four different flavors: chocolate, vanilla, strawberry, and red velvet. They sell 240 chocolate, 150 vanilla, 120 strawberry, and the rest are red velvet. What percentage of the cupcakes sold are red velvet? | def solve() -> int:
total_cupcakes = 600
chocolate_cupcakes = 240
vanilla_cupcakes = 150
strawberry_cupcakes = 120
red_velvet_cupcakes = total_cupcakes - chocolate_cupcakes - vanilla_cupcakes - strawberry_cupcakes
percentage_red_velvet = (red_velvet_cupcakes/total_cupcakes)*100
result = perc... |
A new phone costs $399.99. A store offers a deal where you can get 10% off any purchase over $350. Does the customer qualify for the deal? How much will the phone cost if the deal applies? | def solve() -> int:
phone_price = 399.99
if phone_price > 350:
discount = phone_price * 0.1
final_price = phone_price - discount
result = final_price
else:
result = phone_price
return result
|
Jacob bought a pack of pencils for $6. Each pencil costs 25 cents. How many pencils did he buy? | def solve() -> int:
cost_per_pencil = 0.25
total_cost = 6
result = int(total_cost / cost_per_pencil)
return result
|
Student: **** Ahmed filled his swimming pool with 200liters of water and it took him 1 minute to do the job. How many liters per second was he able to fill the pool with? | def solve() -> int:
water = 200
time = 1
time = time * 60
rate = water / time
result = rate
return result
|
A basketball player earns $25 per game. If they've earned $200, how many games have they played? | def solve() -> int:
earnings_per_game = 25
total_earnings = 200
games_played = total_earnings / earnings_per_game
result = games_played
return result
|
The seats in an auditorium that holds 500 people are taken by 3/5 of the people. How many seats are still available? | def solve() -> int:
cats = 500
seats_taken = 3/5
seats_available = cats * (1 - seats_taken)
result = round(seats_available)
return result
|
Sarah baked 24 cookies. She ate 1/3 of them and gave half of the rest to her friend. How many cookies does Sarah have left? | def solve() -> int:
total_cookies = 24
cookies_after_eating = total_cookies - (1/3) * total_cookies
cookies_after_giving = (1/2) * (cookies_after_eating)
result = cookies_after_giving
return result
|
At the zoo, the Brown family saw 5 lions, 3 tigers, and 2 cheetahs. Unfortunately, 2 of the lions were sleeping and couldn't be seen. If each animal has 4 paws, how many paws did the family see in total? | def solve() -> int:
lions = 5
tigers = 3
cheetahs = 2
sleeping_lions = 2
visible_lions = lions - sleeping_lions
total_paws = (visible_lions + tigers + cheetahs) * 4
result = total_paws
return result
|
Student: An art student needs to draw a rectangular painting with a width of 7 cm and an area of 42 cm². What should the length of the painting be? | def solve() -> int:
width = 7
area = 42
length = area / width
result = length
return result
|
In 5 years, Sarah will be three times her brother's age. If her brother is now 7, how old is Sarah now? | def solve() -> int:
brother_age = 7
ratio_of_ages = 3
diff_between_ages = 5
sarah_age = (ratio_of_ages * brother_age) - (ratio_of_ages - 1) * diff_between_ages
result = sarah_age
return result
|
Oliver bought 30 marbles and equally distributed them among his 6 cousins. When his grandfather came, he realized no marble was left for him. Feeling unhappy, they decided to give him one-half of their marbles. His grandfather then gave 5 marbles to his grandmother and kept 3. How many marbles did Oliver's grandfather ... | def solve() -> int:
marbles = 30
cousins = 6
grandfather_share = marbles // cousins
grandfather_marbles = cousins * grandfather_share
remaining_marbles = marbles - grandfather_marbles
grandfather_marbles += remaining_marbles // 2
grandfather_marbles -= 3
grandfather_marbles += 5
resu... |
If the probability of catching fish in a specific location starts at 20% and increases by 5% for every hour spent fishing, what is the probability that Mark, who fished for 3 hours, will catch a fish? | def solve() -> int:
p_start = 0.2
p_increase = 0.05
hours_fishing = 3
p_final = p_start + p_increase * hours_fishing
result = p_final
return result
|
A rectangle has an area of 56 square units. Its length is 4 units more than 3 times the width. What are the dimensions of the rectangle? | def solve() -> int:
width = 4
length = 4 + 3*width
result = (width, length)
return result
|
The ratio of girls to boys in a class is 5:3. If there are 24 students in the class, how many boys are there? | def solve() -> int:
total_ratio = 5 + 3
boys_ratio = 3 / total_ratio
boys_count = boys_ratio * 24
result = boys_count
return result
|
6. The arts and crafts store bought 5 crates of paint. In each crate, there were 76 cans, each of which cost $5. How much money did the store spend on the paint? | def solve() -> int:
numCrates = 5
numCans = 76
pricePerCan = 5
cost = numCrates * numCans * pricePerCan
result = cost
return result
|
Joey has 5 more than three times as many pencils as Ross. If Ross has 7 pencils, how many pencils do they have together? | def solve() -> int:
ross_pencils = 7
joey_pencils = 3*ross_pencils + 5
total_pencils = ross_pencils + joey_pencils
result = total_pencils
return result
|
Six years from now, Sophia will be four times as old as Ethan. If Ethan is currently fourteen years old, how old is Sophia? | def solve() -> int:
ethan_age = 14
sophia_age = ethan_age * 4 - 6
result = sophia_age
return result
|
Colin has a jar of coins that contains 50 coins. He knows that the jar has 15 quarters, 10 dimes, 5 nickels, and some pennies. He wants to count the total value of the coins in the jar. How much money does he have in the jar? | def solve() -> int:
quarter_value = 0.25
dime_value = 0.1
nickel_value = 0.05
penny_value = 0.01
quarters = 15 * quarter_value
dimes = 10 * dime_value
nickels = 5 * nickel_value
total_coins = 50
pennies = total_coins - (15 + 10 + 5)
pennies = pennies * penny_value
to... |
A Burmese python grew from 1 meter to 5 meters in 462 days. If the snake continues to grow at the same rate, how long will it take for the python to double in length? | def solve() -> int:
start_length = 1
final_length = 5
num_days = 462
goal_length = start_length * 2
growth_rate = (final_length - start_length) / num_days
time_to_double = (goal_length - start_length) / growth_rate
result = time_to_double
return result
|
Mary wants to put a wire fence around her rectangular vegetable garden that has an area of 500 square feet. The fence on the shorter ends of the garden is to be 4 feet high and the sides are to be 6 feet high. What is the total length of wire fencing? | def solve() -> int:
area = 500
shorter_end_height = 4
longer_side_height = 6
width = area / shorter_end_height
length = area / width
shorter_end_fencing = 2 * (length + shorter_end_height)
longer_side_fencing = 2 * (width * longer_side_height)
fencing_l... |
On a flight from New York to Los Angeles, an airplane carried 200 passengers. On the return trip from Los Angeles to New York, it carried 180 passengers. If the plane made five more round trips carrying the same number of passengers on each trip, what is the total number of passengers transported? | def solve() -> int:
ny_to_la = 200
la_to_ny = 180
total_passengers = ny_to_la + la_to_ny
round_trips = 5
total_passengers += round_trips * (ny_to_la + la_to_ny)
result = total_passengers
return result
|
Sophia promised to meditate for 20 minutes every day for 7 days a week. On Sunday, she only meditated for 10 minutes, but made up for it by meditating for 30 minutes on Monday. How many total minutes did Sophia meditate for that week? | def solve() -> int:
sunday_minutes = 10
daily_minutes = 20
monday_minutes = 30
total_minutes = sunday_minutes + (6 * daily_minutes) + monday_minutes
result = total_minutes
return result
|
Tom earned $15 on Monday, $20 on Tuesday, $35 on Wednesday, and $10 on Thursday. If he spends $20 on Friday, how much money will he have left? | def solve() -> int:
balance = 15 + 20 + 35 + 10 - 20
result = balance
return result
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.