question stringlengths 11 2.89k | code stringlengths 20 7.24k |
|---|---|
Ana and Ben share a box of chocolates. The box contains 24 chocolates, 12 of which are dark and 12 are milk. Ana eats 4 dark chocolates and Ben eats 6 milk chocolates. What is the ratio of dark to milk chocolates left in the box? | def solve() -> int:
chocolates = 24
dark_chocolates = 12
milk_chocolates = 12
ana_eats = 4
ben_eats = 6
dark_left = dark_chocolates - ana_eats
milk_left = milk_chocolates - ben_eats
ratio = dark_left / milk_left
result = ratio
return result
|
Student: Sara's bakery sells cupcakes for $2.50 each. She sold 3 dozen cupcakes and earned $90 in total. At the same price, how many more cupcakes does she need to sell to make $140 in total? | def solve() -> int:
price_per_cupcake = 2.50
dozen_sold = 3
total_earned = 90
target_total = 140
cupcakes_sold = dozen_sold * 12
total_from_cupcakes = cupcakes_sold * price_per_cupcake
difference = target_total - total_earned
cupcakes_needed = difference / price_per_cupcake
total_cup... |
An apartment building has 12 floors. It takes 8 seconds to go up the stairs to the floors divisible by 3 and 11 seconds to go up to the others. How many minutes does it take to get to the 12th floor? | def solve() -> int:
floors = 12
time_divisible_by_3 = 8
time_not_divisible_by_3 = 11
total_time = (floors // 3) * time_divisible_by_3 + (floors - (floors // 3)) * time_not_divisible_by_3
minutes = total_time // 60
result = minutes
return result
|
Student: Patrick weights 60 kg and exerts a force of 50 N. How far will Patrick move in 10 seconds, assuming no friction? | def solve() -> int:
mass = 60
force = 50
time = 10
acceleration = force / mass
distance = 0.5 * acceleration * (time ** 2)
result = distance
return result
|
A farmer planted a field of corn, which produced 30 ears of corn. If each ear of corn has an average of 500 kernels, how many kernels are there in the field? | def solve() -> int:
ears = 30
kernels_per_ear = 500
total_kernels = ears * kernels_per_ear
result = total_kernels
return result
|
To convince her husband to eat healthier, theEmma buys a dress for $80, which is 25% less than what Mia bought the same dress for. How much did Mia pay for her dress? | def solve() -> int:
Mia_price = 106.67
result = Mia_price
return result
|
A car travels a distance of 120 km in 2 hours. If the car maintains the same speed, how many hours will it take to travel a distance of 180 km? | def solve() -> int:
speed = 120/2
time = 180/speed
result = time
return result
|
An amusement park charges an entrance fee of $25 for adults and $20 for children. A group of 4 adults and 2 children visit the park together. How much will the group spend on entrance fees in total? | def solve() -> int:
adult_cost = 25
child_cost = 20
num_adults = 4
num_children = 2
total_cost = (adult_cost*num_adults)+(child_cost*num_children)
result = total_cost
return result
|
A family is going out for a meal at a local restaurant. Their total bill comes to $85.00, and the state sales tax is 7.75%. In addition, the family left a 20% gratuity. How much did they pay in total? | def solve() -> int:
total_bill = 85
taxes = total_bill * 0.0775
tip = total_bill * 0.2
total_cost = total_bill + taxes + tip
result = total_cost
return result
|
A box of 25 pens is sold at $15. If a store wants to sell each pen at $0.75, what is the revenue if all the pens are sold? | def solve() -> int:
total_pens = 25
price_per_pen = 0.75
total_revenue = total_pens*price_per_pen
result = total_revenue
return result
|
Possible questions and programs: Lisa had 15 stickers. She gave some of them to her friend Kate, who now has 24 stickers. How many stickers did Lisa give to Kate? | def solve() -> int:
stickers_Lisa = 15
stickers_Kate = 24
stickers_given = stickers_Kate - stickers_Lisa
result = stickers_given
return result
|
Student: Lynda bought a pack of 5 markers for $2.50. What is the cost of each marker? | def solve() -> int:
markers = 5
cost = 2.50
cost_per_marker = cost / markers
result = cost_per_marker
return result
|
Result: 7.50 A phone company charges $30 for the first 2GB of data and $5 for each additional GB of data used. If a customer uses 5.5GB of data, how much will their bill be? | def solve() -> int:
data_used = 5.5
base_price = 30
overage_price = 5
if data_used <= 2:
total_cost = base_price
else:
total_cost = base_price + ((data_used - 2) * overage_price)
result = total_cost
return result
|
Ryan has nine tests in his Math class. He earns 89, 82, 90, 79, 83, 78,76, 92 and 81. What must he earn on his tenth and final test to have an overall average of 87? | def solve() -> int:
a = 89
b = 82
c = 90
d = 79
e = 83
f = 78
g = 76
h = 92
i = 81
count = 10
total = a+b+c+d+e+f+g+h+i
result = (total + 87*count - count)/count
return result
|
A group of friends decide to split a bill at a restaurant. The total bill is $150, and they agree to split the bill equally among them, except for John, who had $20 less than everyone else. If there were 8 people at the table, how much did John pay? | def solve() -> int:
total_bill = 150
num_people = 8
bill_per_person = total_bill / num_people
joh_bill = bill_per_person - 20
result = joh_bill
return result
|
A math quiz has 10 questions and each question is worth 10 points. What percentage of the total score did a student get if they answered 7 questions correctly? | def solve() -> int:
num_questions = 10
points_per_question = 10
total_points = num_questions * points_per_question
correct_answers = 7
score = correct_answers * points_per_question
percentage = score / total_points * 100
result = percentage
return result
|
Student: John runs a toy manufacturing company. He has a production cost of $7 for each toy and sells them at $15 each. He needs to pay $12,000 in rent, and 25% of his profit goes to taxes. He also needs to pay $3,000 to each of his 3 employees. If he sells 6000 toys in one month, what is his profit or loss? | def solve() -> int:
production_cost = 7
selling_price = 15
rent = 12000
tax_percentage = 0.25
employee_salary = 3000
toys_sold = 6000
total_cost = production_cost * toys_sold + rent + employee_salary * 3
total_revenue = selling_price * toys_sold
profit = total_revenue - total_cost
... |
Daniel is organising a picnic. He has two rectangular plates and each plate is 18 centimetres long and 28 centimetres wide. How much area will they use in total? | def solve() -> int:
length = 18
width = 28
totalArea = 2 * length * width
result = print("The total area of the two plates is", totalArea, "square centimetres.")
return result
|
If a car travels 60 miles in 1 hour and 30 minutes, what is its average speed in mph? | def solve() -> int:
distance = 60
time_hours = 1 + 30/60
average_speed = distance / time_hours
result = average_speed
return result
|
There are 30 students in a class. Each student has to write an essay, which is 10 pages long. After grading, the teacher finds that each student has on average written 20% less than required. How many pages did the entire class write? | def solve() -> int:
students = 30
essay = 10
pages = students * essay
less = pages * 0.2
result = pages - less
return result
|
Keith and Lily were collecting cans for recycling. They got $0.05 for each can. Keith collected 120 cans and Lily collected 80 cans. They decided to split the money evenly. How much money did each of them get? | def solve() -> int:
total = (120 + 80) * 0.05
money = total / 2
result = money
return result
|
At the pet store, Jacob saw 15 dogs, 4 cats, and 1 parrot. How many tails were there in total on the animals Jacob saw? Linda went to the optometrist for an eye checkup. The visit cost $250, and her insurance covered 80%. She also had to buy new contact lenses for $90, and her insurance covered 50%. How much did Linda ... | def solve() -> int:
dogs = 15
cats = 4
parrot = 1
total_tails = (dogs * 1) + (cats * 1) + (parrot * 1)
visit_cost = 250
visit_coverage = 0.8
contact_lenses_cost = 90
contact_lenses_coverage = 0.5
total_cost = (visit_cost * (1 - visit_coverage)) + (contact_lenses_cost *... |
Taylor has 12 more stickers than Madison does. If Madison has 18 stickers, how many more stickers will Madison have than Taylor if her grandpa gives her 15 stickers? | def solve() -> int:
madison_stickers = 18
taylor_stickers = madison_stickers + 12
grandpa_stickers = 15
total_madison_stickers = madison_stickers + grandpa_stickers
total_taylor_stickers = taylor_stickers
difference = total_madison_stickers - total_taylor_stickers
result = dif... |
A recipe calls for 2 cups of sugar for 8 servings. If there are 24 servings, how many cups of sugar are needed? | def solve() -> int:
cups_per_serving = 2 / 8
cups_needed = cups_per_serving * 24
result = cups_needed
return result
|
A classroom has 20 students, if each student has 4 crayons, how many crayons are in total? | def solve() -> int:
num_students = 20
num_crayons_per_student = 4
total_crayons = num_students * num_crayons_per_student
result = total_crayons
return result
|
Jasmine has 140 marbles. She gave away 25 marbles. How many marbles does Jasmine have left? | def solve() -> int:
original_marbles = 140
marbles_given_away = 25
marbles_left = original_marbles - marbles_given_away
result = marbles_left
return result
|
Possible new questions: Maya has 12 stickers in her album. She gives one-third of them to her friend Lena. She then buys 8 more stickers from the store. How many stickers does Maya have now? | def solve() -> int:
stickers = 12
stickers -= stickers // 3
stickers += 8
result = stickers
return result
|
Sarah needs to paint a rectangular wall that is 8 feet wide and 10 feet tall. If a gallon of paint covers 100 square feet, how many gallons of paint does Sarah need to buy? | def solve() -> int:
width = 8
height = 10
sqft_per_gallon = 100
total_sqft = width * height
gallons_of_paint = total_sqft / sqft_per_gallon
result = f'<<<{gallons_of_paint}>>>'
result = gallons_of_paint
return result
|
John has $5000 in his savings account. He deposits $1000 in the first month, and then withdraws $2000 in the second month. In the third month, he deposits twice the amount he deposited in the first month. How much money does John have in his savings account after 3 months? | def solve() -> int:
savings_account = 5000
savings_account += 1000
savings_account -= 2000
savings_account += (2*1000)
result = savings_account
return result
|
Hannah was able to solve 10 math problems in an hour last year. This year, she solved 3 more problems than her brother who solved 2 problems. How many math problems did Hannah solve this year? | def solve() -> int:
hannah_last_year = 10
brother = 2
hannah_this_year = brother + 3
result = hannah_this_year
return result
|
If an instructor has a total of 78 students and wants to divide them into groups of 4, how many groups are there? | def solve() -> int:
students = 78
group_size = 4
result_groups = int(students/group_size)
result = result_groups
return result
|
The sum of Jeff and Lisa's ages is currently 50 years. If Jeff is 10 years older than Lisa, what is Jeff's age? | def solve() -> int:
Jeff_Lisa = 50
Lisa_age = (Jeff_Lisa-10)/2
Jeff_age = Lisa_age + 10
result = Jeff_age
return result
|
5. Tina goes to the store and buys 3 shirts. Each shirt costs $20. She then decides to use a coupon which gives a 15% discount. How much did she pay in total? | def solve() -> int:
cost = 20 * 3
cost *= 0.85
result = cost
return result
|
A company produced 600 units of a product. After quality control, 50 units were rejected. On Monday, 100 units were sold. On Tuesday, 20% of the remaining units were sold. After that, 80 more units were produced. How many units are there now in total? | def solve() -> int:
units_produced = 600
defective_units = 50
monday_sold = 100
remaining_units1 = units_produced - defective_units - monday_sold
tuesday_sold = int(remaining_units1 * 0.2)
remaining_units2 = remaining_units1 - tuesday_sold
new_production = 80
total_units = remaining_unit... |
Student: Jill makes $12 of profit each time she sells 4 baseball caps, and 8 times as much profit when she sells two pairs of shoes. How much profit will she make if she sells 7 baseball caps and 3 pairs of shoes? | def solve() -> int:
profit_per_cap = 12 / 4
profit_per_shoe = 8 * profit_per_cap
caps_sold = 7
shoes_sold = 3
profit_from_caps = profit_per_cap * caps_sold
profit_from_shoes = profit_per_shoe * shoes_sold
total_profit = profit_from_caps + profit_from_shoes
result = total_profit
... |
It takes Sarah 8 hours to clean the house, which is twice the time she needs to run errands. If she needs to run errands for 12 hours, how many hours does she take to clean the house? | def solve() -> int:
x = 2 * 12
result = x
return result
|
Student: Emma buys 2 bags of apples and 3 bags of oranges for $20 in total. Each bag of apples costs $4 and each bag of oranges costs $3. How much money did Emma spend on buying 2 bags of apples and 3 bags of oranges? | def solve() -> int:
num_apples = 2
price_apples = 4
num_oranges = 3
price_oranges = 3
total_cost = num_apples * price_apples + num_oranges * price_oranges
result = total_cost
return result
|
If a squid has twice as many legs as an octopus, and the octopus has 8 legs, how many legs does the squid have? | def solve() -> int:
octopus_legs = 8
squid_legs = 2 * octopus_legs
result = squid_legs
return result
|
A school has 500 students, and the ratio of boys to girls is 2:3. How many girls attend the school? | def solve() -> int:
total_students = 500
boy_to_girl_ratio = 2/3
girls = total_students / (1 + boy_to_girl_ratio)
result = girls
return result
|
A cyclist rides 20km in 1 hour and 30 minutes. What is their average speed in km/h? | def solve() -> int:
distance = 20
time_in_hours = 1.5
average_speed = distance / time_in_hours
result = round(average_speed, 2)
return result
|
Olivia reads books for 3 hours every day. On the days she plays video games, she plays for one-fourth the time that she reads. If she plays video games 6 times a week, how long does she spend reading books and playing video games? | def solve() -> int:
hours_per_day = 3
video_game_time = hours_per_day / 4
video_game_days = 6
total_video_game_time = video_game_time * video_game_days
total_reading_time = hours_per_day * 7
total_time_spent = total_video_game_time + total_reading_time
result = total_time_spent
return re... |
If the cost of one laptop is $1000, how much will 5 laptops cost? | def solve() -> int:
cost_of_one_laptop = 1000
cost_of_five_laptops = cost_of_one_laptop * 5
result = cost_of_five_laptops
return result
|
In a class of 30 students, 18 are girls. What is the ratio of boys to girls? | def solve() -> int:
total_students = 30
girls = 18
boys = total_students - girls
ratio = boys / girls
result = ratio
return result
|
There are 70 students in a classroom. If the ratio of the number of boys to girls is 4:3, how many girls are in the classroom? | def solve() -> int:
total_students = 70
boy_to_girl_ratio = 4/3
num_girls = total_students / (1 + boy_to_girl_ratio)
result = num_girls
return result
|
Student: Claire and Emma went shopping at a fashion store. Claire spent one third of the total money that they both spent and Emma spent three fourth of the total money they both spent. If their total spending is $72, calculate the amount of money that Claire spent. | def solve() -> int:
total = 72
claire = 0
emma = 0
claire = total / 3
emma = total * 3 / 4
sum = claire + emma
result = claire
return result
|
Noah has 15 cupcakes to share equitably with his five teammates. How many cupcakes will each teammate get to eat? | def solve() -> int:
cupcakes = 15
teammates = 5
cupcakes_per_teammate = cupcakes / teammates
result = cupcakes_per_teammate
return result
|
David wants to take out a mortgage of $500,000 for a new home. The interest rate starts at 4% and increases by 0.5% every year. If David plans to pay back the mortgage in 30 years, how much in interest will he have to pay? | def solve() -> int:
loan_amount = 500000
interest_rate = 0.04
years = 30
total_interest = 0
for i in range(years):
interest = loan_amount * interest_rate
total_interest += interest
loan_amount += interest
interest_rate += 0.005
result = total_interest
... |
Leo likes to play video games. He bought 5 new games and 3 used games. Each new game cost $20 and each used game cost $10. He also sold 2 of his old games for $8 each. How much did Leo spend in all? | def solve() -> int:
new_game_cost = 20
used_game_cost = 10
new_game_total = 5 * new_game_cost
used_game_total = 3 * used_game_cost
old_game_income = 2 * 8
net_spent = new_game_total + used_game_total - old_game_income
result = net_spent
return result
|
A recipe uses 2 cups of sugar to make 24 cookies. How many cups of sugar are needed to make 96 cookies? | def solve() -> int:
cups_sugar_per_cookie = 2 / 24
cups_sugar = cups_sugar_per_cookie * 96
result = cups_sugar
return result
|
Bert is storing pennies in a cylindrical bank that has a radius of 5 cm and a height of 20 cm. He knows that each penny has a diameter of 1.9 cm and a thickness of 0.15 cm. He has already filled the bank with 100 pennies stacked flat on the bottom. How many more pennies can he fit in the bank if he stacks them vertical... | def solve() -> int:
bank_volume = 3.14 * (5 ** 2) * 20
penny_volume = 3.14 * (0.95 ** 2) * 0.15
bottom_volume = 100 * penny_volume
remaining_volume = bank_volume - bottom_volume
vertical_pennies = remaining_volume / penny_volume
result = int(vertical_pennies)
return... |
A baker had 240 muffins in a tray he was using to prepare for a party. He added chocolate chips to 1/3 of the muffins and blueberries to 1/4 of the muffins. The rest of the muffins were plain. How many plain muffins did he have? | def solve() -> int:
total = 240
choco = 1/3 * total
blue = 1/4 * total
plain = total - choco - blue
result = plain
return result
|
A farmer has 14 cows and 3 horses. Each cow requires 3 kg of hay per day and each horse requires 5 kg of hay per day. If the farmer has 80 kg of hay available per day, how long will the hay last? | def solve() -> int:
cows = 14
horses = 3
hay_per_cow = 3
hay_per_horse = 5
total_hay = cows * hay_per_cow + horses * hay_per_horse
days_of_hay = 80 // total_hay
result = days_of_hay
return result
|
A pizza shop is selling pizza slices for $3 each. The pizza shop has a loyalty program that for every 8 slices bought, the customer gets 2 free slices. A group of friends wants to buy as many slices as possible with $50. How many slices can they buy and how much money will they have left? | def solve() -> int:
slices = (50 // 24) * 10
money = 50 % 24
result = (slices, money)
return result
|
A toy store has 80 stuffed animals. One fourth of them are bears, and three fifths of the bears have a bow tie. How many bears with a bow tie are in the store? | def solve() -> int:
total_animals = 80
bears = total_animals // 4
bears_with_ties = bears * 3/5
result = bears_with_ties
return result
|
Nina works in a school that has 120 teachers, with 60% of them being women. Nina is part of a committee of 12 teachers who are selected randomly from the school to plan a staff event. The committee has the same percentage of women as the school. How many women and men are in the committee? | def solve() -> int:
x = None
y = None
x = 0.6 * 12
y = 12 - x
x = round(x)
y = round(y)
result = (x, y)
return result
|
Ella can run 6 miles an hour, while Olivia runs 7 miles an hour. If Ella starts running at 11:30am and Olivia started running 15 minutes later, what time will they both finish if the total distance is 12 miles? | def solve() -> int:
total_distance = 12
speed_ella = 6
speed_olivia =7
time_ella_started = 690
time_olivia_started = time_ella_started + 15
time_ella_took = total_distance/speed_ella
time_olivia_took = total_distance/speed_olivia
result = time_ella_started + time_ella_took +time_oliv... |
Tom has a book with 120 pages. He reads 10 pages every day. How many days does it take him to finish the book? | def solve() -> int:
pages = 120
pages_per_day = 10
days = pages // pages_per_day
result = days
return result
|
John gathered 75 cherries from his cherry tree and 5 times as many grapes from his grape vine. What is the difference between the number of the two fruits? | def solve() -> int:
cherries = 75
grapes = 5 * cherries
difference = cherries - grapes
result = abs(difference)
return result
|
Each month, Jason buys 57 bananas to eat as a snack. However, his cat knocked over his bag, causing 14 bananas to fall out. When Jason got home, he only had 16 bananas left. How many bananas did Jason's cat knock out of his bag? | def solve() -> int:
bananas_bought = 57
bananas_left = 16
bananas_knocked_out = bananas_bought - bananas_left
result = bananas_knocked_out + 14
return result
|
David and Chris just finished picking apples. David has 5 times as many apples as Chris. The total weight of the apples is 25 pounds. If David has 50 apples, how many apples does Chris have and what is their weight in grams? | def solve() -> int:
david_apples = 50
chris_apples = david_apples / 5
total_weight = 25
weight_per_apple = total_weight / david_apples
chris_weight_grams = chris_apples * weight_per_apple * 1000
result = f'Chris has {chris_apples} apples and their weight in grams is {chris_weight_... |
In a zoo, the number of giraffes is 80 more than the number of zebras. If there are 400 giraffes in the zoo, calculate the total number of animals present in the zoo. | def solve() -> int:
giraffes = 400
zebras = giraffes - 80
result = giraffes + zebras
return result
|
``` A toy store has 1500 toys in stock. On the first day, 100 toys are sold, and then 75 more are sold the second day. How many toys are remaining in stock? | def solve() -> int:
num_toys = 1500
num_sold_first = 100
num_sold_second = 75
num_left = num_toys - num_sold_first - num_sold_second
result = num_left
return result
|
Samantha has 8 books and 12 magazines in her bookshelf. Her brother gives her 1/2 times as many books and 1/4 times as many magazines. If Samantha donates 1/3 of her reading materials, how many items will be left in her bookshelf? | def solve() -> int:
books = 8
magazines = 12
brother_books = 1/2 * books
brother_magazines = 1/4 * magazines
total_books = books + brother_books
total_magazines = magazines + brother_magazines
total_reading_materials = total_books + total_magazines
donated_materials =... |
90% of all cars on a busy street are black. If there are 200 cars on the street, how many of them are not black? | def solve() -> int:
black_cars = 0.9 * 200
not_black_cars = 200 - black_cars
result = not_black_cars
return result
|
A car drives 300 miles in 5 hours. What is the average speed of the car in miles per hour? | def solve() -> int:
miles_driven = 300
time_taken = 5
average_speed = miles_driven / time_taken
result = average_speed
return result
|
A recipe calls for 2/3 cup of milk per 1/2 cup of flour. If you use 3 cups of flour, how many cups of milk are needed? | def solve() -> int:
flour = 3
milk_per_flour = 2/3 / (1/2)
milk = milk_per_flour * flour
result = milk
return result
|
John can lift 50 pounds of weights in an hour. If he lifts weights for 2 hours every day, how many days will it take him to lift a total of 800 pounds of weights? | def solve() -> int:
lift_per_hour = 50
hours_per_day = 2
total_lift = 800
hours_needed = total_lift / (lift_per_hour * hours_per_day)
days_needed = hours_needed / 24
days_needed = int(days_needed) + 1
result = days_needed
return result
|
A shirt cost $27. If it's on sale for 25% off, what is the new price? | def solve() -> int:
discount = 0.25
original_price = 27
new_price = original_price * (1 - discount)
result = new_price
return result
|
Possible questions and programs are: Anna and Ben each had $15 and they went to a bookstore. Anna bought 2 magazines for $3.50 each and a bookmark for $0.75. Ben bought a paperback for $7.99 and a pen for $1.25. They both had a coupon for 10% off their total purchase. How much money did they have left in total? | def solve() -> int:
anna_subtotal = 2 * 3.50 + 0.75
ben_subtotal = 7.99 + 1.25
anna_tax = 0.07 * anna_subtotal
ben_tax = 0.07 * ben_subtotal
anna_total = (anna_subtotal + anna_tax) * 0.9
ben_total = (ben_subtotal + ben_tax) * 0.9
anna_change = 15 - anna_total
ben_change = 15 - ben_total... |
Ella bought a dress that was originally $80. The dress was on sale for 25% off. She also had to pay 10% sales tax on the discounted price. How much did she pay for the dress? | def solve() -> int:
discount = 80 * 0.25
discounted_price = 80 - discount
tax = discounted_price * 0.1
total_price = discounted_price + tax
result = total_price
return result
|
Student: A tank can hold 1000 liters of water. If 200 liters of water are removed, what percentage of the tank's capacity has been removed? | def solve() -> int:
tank_capacity = 1000
water_removed = 200
percentage_removed = (water_removed / tank_capacity) * 100
result = percentage_removed
return result
|
At a bike race, 100 participants entered but only 80 showed up to race. This year, the race organizers are expecting eight times as many participants as last year. How many people are expected to participate this year? | def solve() -> int:
participants_last_year = 80
participants_this_year = participants_last_year * 8
result = participants_this_year
return result
|
John had 120 apples. He gave away 1/4 of them and divided the remainder equally between 3 friends. How many apples did each friend get? | def solve() -> int:
apples = 120
givenAway = (apples/4)
remainder = apples - givenAway
numFriends = 3
eachFriend = remainder/numFriends
result = eachFriend
return result
|
A factory produced 7500 units in January, 8000 units in February, and 9000 units in March. If they want to maintain an average of 8500 units per month for the first quarter of the year, how many units should they produce in April? | def solve() -> int:
total_q1 = 7500 + 8000 + 9000
avg_q1 = total_q1 / 3
april_target = (4 * 8500) - total_q1
result = april_target
return result
|
Nick has collected 32 stones and he wants to put them into 8 jars evenly. How many stones should he put into each jar? | def solve() -> int:
totalStones = 32
numOfJars = 8
stonesPerJar = totalStones // numOfJars
result = stonesPerJar
return result
|
Sarah buys 10 pounds of flour. She uses all but 3 pounds to bake bread. She uses five times as many cups of water as flour. How many cups of water did she use? | def solve() -> int:
flour = 10
remaining_flour = flour - 3
cups_of_water = 5 * remaining_flour
result = cups_of_water
return result
|
Jason purchased 30 yards of fabric and cut it into 10 equal portions. If he used 7 parts of the fabric, how many yards of fabric were left unused? | def solve() -> int:
total_yards = 30
num_portions = 10
portion_size = total_yards / num_portions
num_used = 7
yards_used = portion_size * num_used
yards_unused = total_yards - yards_used
result = yards_unused
return result
|
Rachel delivers newspapers to earn money. She gets paid 4 cents for each newspaper she delivers. On average, how many minutes can she take to deliver a newspaper if she wants to earn $14 an hour? | def solve() -> int:
newspaper_pay = 0.04
hourly_pay = 14
minutes_in_hour = 60
earnings_per_minute = newspaper_pay / minutes_in_hour
minutes_per_newspaper = hourly_pay / (earnings_per_minute * 60)
result = minutes_per_newspaper
return result
|
A baseball player had a batting average of. 333 after getting 15 hits in 45 at-bats. How many hits would he need in 30 at-bats to raise his batting average to. 400? | def solve() -> int:
at_bats = 45
current_hits = 15
current_batting_average = current_hits / at_bats
target_batting_average = 0.4
target_at_bats = 30
target_hits = (target_at_bats * target_batting_average) - (at_bats * current_batting_average) + current_hits
result = int(target_hits)
ret... |
Jenny can run 6 miles in 55 minutes. What is her average speed in miles per hour? | def solve() -> int:
time_in_hours = 55/60
distance = 6
speed = distance/time_in_hours
result = speed
return result
|
Anna cut a pizza into 8 slices and ate 3 of them. She shared the remaining slices with her 4 friends. How much pizza did each friend get? | def solve() -> int:
shared = 8 - 3
pizza_per_friend = shared / 4
result = pizza_per_friend
return result
|
Student: Trent has 4 water bottles, each of which holds 17 ounces of water. He has already filled 3 of the bottles with water. How much water is still needed to fill the 4th bottle? | def solve() -> int:
bottles = 4
ounces_per_bottle = 17
filled_bottles = 3
total_ounces = bottles * ounces_per_bottle
filled_ounces = filled_bottles * ounces_per_bottle
remaining_ounces = total_ounces - filled_ounces
result = remaining_ounces
return result
|
Student: A car travels at a speed of 50 km/h for 4 hours. How far does it travel? | def solve() -> int:
speed = 50
time = 4
distance = speed * time
result = distance
return result
|
Grace, Harry, and Ivan planted flowers in their garden. Grace planted 20 flowers and Harry planted 10 more than Grace. Ivan planted half of the total number of flowers that Grace and Harry planted. If each flower had 5 petals and they counted the total number of petals in their garden, how many petals did they count? | def solve() -> int:
ivan_flowers = (20 + 20 + 10) / 2
total_flowers = 20 + 20 + 10 + ivan_flowers
result = total_flowers * 5
return result
|
Mia wants to bake a cake for her friend's birthday. She needs 2 cups of flour, 1.5 cups of sugar, 0.5 cups of oil, and 3 eggs for the cake. She also needs 1.5 cups of whipped cream and 0.5 cups of strawberries for the frosting. She has 4 cups of flour, 3 cups of sugar, 1 cup of oil, 6 eggs, 2 cups of whipped cream, and... | def solve() -> int:
flour_per_cake = 2
sugar_per_cake = 1.5
oil_per_cake = 0.5
eggs_per_cake = 3
whipped_cream_per_cake = 1.5
strawberries_per_cake = 0.5
flour = 4
sugar = 3
oil = 1
eggs = 6
whipped_cream = 2
strawberries = 1
cakes_with_flour = flour // flou... |
Student: Eric gets paid $12 per hour. If he works 35 hours in a week, how much does he earn? If he works an extra 10 hours the following week, what is his total pay for two weeks? | def solve() -> int:
hourly_pay = 12
hours_week1 = 35
hours_week2 = 10
earnings_week1 = hourly_pay * hours_week1
earnings_week2 = hourly_pay * hours_week2
total_earnings = earnings_week1 + earnings_week2
result = total_earnings
return result
|
Mae is 5 years older than her sister. 5 years ago, she was 8 times her sister's age. How old is she now? | def solve() -> int:
maes_age = 0
sisters_age = 0
maes_age_5years_ago = (sisters_age * 8) + 5
sisters_age = (maes_age_5years_ago - 5) / 8
maes_age = (sisters_age + 5) + 5
result = maes_age
return result
|
A music store owner orders 15 new CDs every week. After 1 month, he had sold 75 CDs but still had 285 CDs in stock. How many CDs did he have originally? | def solve() -> int:
new_cds_per_week = 15
cds_sold_in_month = 75
cds_in_stock_after_month = 285
cds_received_in_month = new_cds_per_week * 4
original_cds = cds_received_in_month + cds_sold_in_month - cds_in_stock_after_month
result = original_cds
return result
|
A painter has a total of 125 cans of paint with 15 of them being empty. How many cans of paint with paint in them does the painter have? | def solve() -> int:
total_cans = 125
empty_cans = 15
filled_cans = total_cans - empty_cans
result = filled_cans
return result
|
Student: A car rental company has 12 cars available for rent. Out of these, 5 are standard and 7 are luxury cars. If the standard cars rent for $18 a day and the luxury cars rent for $40 a day, what is the total potential revenue per day if all cars get rented? | def solve() -> int:
standard_cars = 5
luxury_cars = 7
standard_price = 18
luxury_price = 40
standard_revenue = standard_cars * standard_price
luxury_revenue = luxury_cars * luxury_price
total_revenue = standard_revenue + luxury_revenue
result = total_revenue
return result
|
A rectangle has a length of 8 cm and a width of 5 cm. What is the area of the rectangle? | def solve() -> int:
length = 8
width = 5
area = length * width
result = area
return result
|
Student: Sam bought a TV for $250, a refrigerator for $500, 3 pillows for $15 each and a blanket for $25. He got a 10% discount on all his items. How much did he save? | def solve() -> int:
tv_price = 250
refrigerator_price = 500
pillow_price = 15
blanket_price = 25
discount_rate = 0.1
total_price_before_discount = tv_price + refrigerator_price + pillow_price * 3 + blanket_price
total_price_after_discount = total_price_before_discount * (1 - discount_rate)
... |
John wants to make lemonade for a party of 20 people. The recipe states that he needs 1.5 cups of lemon juice added to 6 cups of water. If John has 3 cups of lemon juice, how many cups of water does he need to add to make the lemonade for 20 people? | def solve() -> int:
people = 20
lemon_juice_per_person = 1.5/6
lemon_juice = people * lemon_juice_per_person
water = lemon_juice * 4
needed_water = water - 3
result = needed_water
return result
|
Cindy walks at 4 miles per hour for 40 minutes, then bikes at 10 miles per hour for 20 minutes before jogging back home at 6 miles per hour for 20 minutes. If she goes on this routine every day, how many miles does she cover in a week? | def solve() -> int:
walking_speed = 4
walking_time = 40
walking_distance = (walking_speed * walking_time) / 60
biking_speed = 10
biking_time = 20
biking_distance = (biking_speed * biking_time) / 60
jogging_speed = 6
jogging_time = 20
jogging_distance = (jogging_speed * jogging_time) ... |
Student: Sarah has a rectangular piece of paper that is 12 cm long and 8 cm wide. She cuts out a 3 cm by 3 cm square from each corner. What is the area of the remaining piece of paper? | def solve() -> int:
length = 12
width = 8
cut_length = 3
cut_width = 3
remaining_length = length - 2 * cut_length
remaining_width = width - 2 * cut_width
result = remaining_length * remaining_width
return result
|
An office has 15 employees. Each employee has an average of 1.5 computer monitors. How many monitors are there in total? | def solve() -> int:
employees = 15
monitors_per_employee = 1.5
total_monitors = employees*monitors_per_employee
result = total_monitors
return result
|
Student: James wants to buy a book that costs $15. However, he lost his library card which has a 20% discount on the book. Without the discount, how much more will James pay? | def solve() -> int:
book_price = 15
discount_percentage = 20
discount_amount = book_price * (discount_percentage/100)
price_without_discount = book_price - discount_amount
difference = book_price - price_without_discount
result = difference
return result
|
Lamar earns $25 per hour as a tutor. He works 20 hours per week during the school year and 40 hours per week during the summer. How much more does he earn in the summer than in the school year? | def solve() -> int:
school_year_income = 25 * 20
summer_income = 25 * 40
income_difference = summer_income - school_year_income
summer_weeks = 10
extra_earnings = income_difference * summer_weeks
result = extra_earnings
return result
|
A company is producing 1200 jars of salsa. Each jar is 12oz. The company needs to know the total amount of salsa in gallons and quarts and how many tomatoes are needed for this production. Assuming 2 pounds of tomatoes yields 1 quart and there are 3 teaspoons of salsa in a jar, what is the total cost of the tomatoes if... | def solve() -> int:
num_jars = 1200
jar_size = 12
total_salsa_oz = num_jars*jar_size
total_salsa_g = total_salsa_oz / 128
total_salsa_q = total_salsa_g * 4
tomato_pound_cost = 2.5
tomatoes_needed = (total_salsa_q / 2) * 2
total_tomato_cost = tomatoes_needed * tomato_pound_cost
result... |
Jim has a total of $800 in his savings account. That is $200 less than twice the amount of money that he has in his checking account. How much money does Jim have in his checking account? | def solve() -> int:
money_in_checking_account = (800 + 200) / 2
result = money_in_checking_account
return result
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.