question stringlengths 11 2.89k | code stringlengths 20 7.24k |
|---|---|
David wants to create a table. He needs to buy different lengths of wood. He needs 4 pieces of 2 meters, 3 pieces of 4 meters and 2 pieces of 3 meters. How many meters of wood does David need to buy in total? | def solve() -> int:
lengths = 2 * 4 + 3 * 4 + 2 * 3
result = lengths
return result
|
A six-layer cake is being baked with each layer having ten times as much vanilla extract as the layer above it. The top layer has three teaspoons of extract. How much vanilla extract is in the cake? | def solve() -> int:
layer6 = 3
layer5 = layer6 / 10
layer4 = layer5 / 10
layer3 = layer4 / 10
layer2 = layer3 / 10
layer1 = layer2 / 10
total_extract = layer1 + layer2 + layer3 + layer4 + layer5 + layer6
result = total_extract
return result
|
John's salary is $2000 per month, and he saves 30% of his salary. He wants to save money to buy a $5000 car. How many months will it take for him to save enough money to buy the car? | def solve() -> int:
salary = 2000
savings_percent = 0.3
car_cost = 5000
savings_per_month = salary * savings_percent
months = car_cost / savings_per_month
result = months
return result
|
A certain stock was worth $50 per share in 2017. Its value increases by 8% each year. How much will it be worth in 2021? | def solve() -> int:
V0 = 50
r = 0.08
t = 2021 - 2017
V = V0*(1+r)**t
result = round(V,2)
return result
|
John reads 6 pages of a book on weekdays and 8 pages on weekends. If it takes 5 weeks for John to finish his book, how many pages that book has? | def solve() -> int:
a = 6
b = 8
total_days = 5 * 7
total_pages = total_days * (a + b)
result = total_pages
return result
|
A breakfast tray consists of 2 eggs, 4 slices of toast, 6 sausages, 1 bowl of cereal, and a carton of milk. One egg costs $1. A slice of toast costs $1.50. A sausage costs $2. A bowl of cereal costs $4, and a carton of milk costs $3. What is the total cost of the breakfast tray? | def solve() -> int:
egg_cost = 1
toast_cost = 1.5
sausage_cost = 2
cereal_cost = 4
milk_cost = 3
total_cost = (2 * egg_cost) + (4 * toast_cost) + (6 * sausage_cost) + cereal_cost + milk_cost
result = total_cost
return result
|
Student: A box of cereal has a mass of 650 grams. If each serving size is 50 grams, how many servings are in the box? | def solve() -> int:
mass_of_box = 650
serving_size = 50
number_of_servings = mass_of_box / serving_size
result = number_of_servings
return result
|
Student: A plane travels from New York to London, a distance of 5,500 kilometers. The plane travels at a speed of 800 kilometers per hour. How long does the trip take and how many stops will be taken on the way, if the plane needs to stop every 2,000 kilometers to refuel? | def solve() -> int:
distance = 5500
speed = 800
time = distance / speed
stops = distance // 2000
total_time = time + stops
result = total_time
return result
|
John needs to buy a new computer. The computer costs $900 and he needs to purchase additional software for a cost of $200. John can get a 12% discount on the price of the computer and a 15% discount on the cost of the software. How much will he pay for everything? | def solve() -> int:
price_computer = 900
price_software = 200
discount_computer = 0.12
discount_software = 0.15
discounted_price_computer = price_computer - (price_computer * discount_computer)
discounted_price_software = price_software - (price_software * discount_software)
t... |
Sophie is an artist who receives 5 sets of 7 canvases each for being the most creative person within her art community. If she already has 35 canvases, how many canvases will she own in 2 years? | def solve() -> int:
sets_of_canvases = 5
canvases_per_set = 7
current_canvases = 35
years = 2
total_canvases = current_canvases + (sets_of_canvases * canvases_per_set * years)
result = total_canvases
return result
|
Alex has 36 toy cars and 28 toy trains. He wants to give 12 cars and 8 trains to each of his two cousins. How many toy cars and toy trains will Alex have left for himself? | def solve() -> int:
total_toys = 36 + 28
toys_given_cousin = (12 + 8)
toys_remaining = total_toys - (toys_given_cousin * 2)
toys_remaining_cars = toys_remaining // 2
toys_remaining_trains = toys_remaining // 2
result = (toys_remaining_cars, toys_remaining_trains)
return result
|
Student: Tiffany paid $13 for a dress that is on a 25% discount. What was the original price? | def solve() -> int:
discount = 0.25
paid = 13
discounted_price = paid / (1 - discount)
original_price = discounted_price / (1 - discount)
result = original_price
return result
|
Possible new questions: Elaine wanted to make some cookies for her friends. She had a recipe that required 2 cups of flour, 1 cup of sugar, and 3/4 cup of butter. However, she only had 1/2 cup of butter left. How many cups of flour and sugar did she need to adjust the recipe proportionally? | def solve() -> int:
butter_ratio = 0.5 / 0.75
flour_amount = 2 * butter_ratio
sugar_amount = 1 * butter_ratio
flour_amount = round(flour_amount, 2)
sugar_amount = round(sugar_amount, 2)
result = (flour_amount, sugar_amount)
return result
|
A grocery store has an offer where you can buy 3 cans of soda for $5. If John buys 9 cans of soda, how much does he save compared to buying each can separately for $2? | def solve() -> int:
soda_bundle = 5
soda_single = 2
bundle_price = (9//3)*soda_bundle
single_price = 9*soda_single
savings = single_price - bundle_price
result = savings
return result
|
In a class of 36 students, the ratio of boys to girls is 2:3. How many girls are there in the class? | def solve() -> int:
boys = 36 / (2+3)
girls = boys * 3
result = girls
return result
|
If it took Emma twice the time it took Alex to finish a 10-mile race, how many miles can Emma run in the same time as it takes Alex to run 5 miles? | def solve() -> int:
alex_time = 1
emma_time = 2 * alex_time
alex_distance = 5
emma_distance = (alex_distance / alex_time) * emma_time
result = emma_distance
return result
|
A car travels 180 miles in 3 hours. What is the average speed of the car in miles per hour? | def solve() -> int:
distance_travelled = 180
time_taken = 3
average_speed = distance_travelled/time_taken
result = average_speed
return result
|
Andrew goes to language school every day for 120 minutes. He spends one fifth of his time studying vocabulary and the rest of the time studying grammar and practicing speaking. If he studies grammar for 3 times the time he practices speaking, how many minutes does he spend practicing speaking each day? | def solve() -> int:
time_vocabulary = 120 / 5
time_remaining = 120 - time_vocabulary
time_speaking = (1/4) * time_remaining
result = time_speaking
return result
|
Student: Tina has a jar with 68 jellybeans. She decides to give some to each of her 4 friends, but keeps 16 for herself. She divides the rest equally among her friends. How many jellybeans will each of her friends get? | def solve() -> int:
jellybeans = 68
tina_jellybeans = 16
friends = 4
friend_jellybeans = (jellybeans - tina_jellybeans) / friends
result = friend_jellybeans
return result
|
A bag of candy has 500 pieces of candy. If there are 5 kids, how many pieces of candy can each kid get if we split it evenly? | def solve() -> int:
number_of_kids = 5
pieces_of_candy = 500
pieces_per_kid = pieces_of_candy / number_of_kids
result = pieces_per_kid
return result
|
Ella baked 6 less than four times as many cookies as Noah. Liam baked twice as many as Ella. Noah baked 18 cookies. How many did Liam bake? | def solve() -> int:
ella_cookies = 4 * 18 - 6
liam_cookies = 2 * ella_cookies
result = liam_cookies
return result
|
The Chess Club offers 3 beginner classes on weekdays and 2 classes on each day of the weekend. Each class has room for 4 people. How many people can take classes in 4 weeks? | def solve() -> int:
weekday_classes = 3
weekend_classes = 2
weeks = 4
class_capacity = 4
total_capacity = (weekday_classes * 5 + weekend_classes * 2) * class_capacity * weeks
result = total_capacity
return result
|
For every 100 grams of chocolate that Michael eats, he gains 2 pounds. If he wants to gain 10 pounds by Valentine's Day and he eats 50 grams of chocolate every day, how many days will he need to eat chocolate? | def solve() -> int:
grams_of_chocolate_per_100g = 100
pounds_gained_per_100g = 2
pounds_goal = 10
grams_of_chocolate_per_day = 50
pounds_gained_per_day = (pounds_gained_per_100g / grams_of_chocolate_per_100g) * grams_of_chocolate_per_day
days_needed = pounds_goal / pounds_gained_per_day
... |
Jordan wants to buy a new smartphone. The store has a 10% sale on all smartphones. If the original price of the smartphone is $1000 and Jordan gets $100 discount, how much money does he pay in total? | def solve() -> int:
original_price = 1000
discount_percentage = 10
discount = original_price * (discount_percentage/100)
total_cost = original_price - discount - 100
result = total_cost
return result
|
A car can travel 324 miles on 12 gallons of gas. How far can it travel on 5 gallons of gas? | def solve() -> int:
distance_1 = 324
gas_1 = 12
gas_2 = 5
rate = distance_1/gas_1
distance_2 = rate * gas_2
result = distance_2
return result
|
A farmer has 28 cows. One-third of them are brown, and half of the remaining are black. How many cows are not brown or black? | def solve() -> int:
cows = 28
brown = cows * (1/3)
remaining = cows - brown
black = remaining * (1/2)
not_bb = cows - brown - black
result = not_bb
return result
|
A group of seven colleagues decided to purchase a new coffee machine worth $500. They intended to split the cost equally, but the boss decided not to join. They received $200 in donations to help cover some of the cost. What is each employee's new contribution towards the coffee machine considering the boss's share is ... | def solve() -> int:
cost_of_coffee_machine = 500
number_of_colleagues = 7
donations_received = 200
total_cost = cost_of_coffee_machine - donations_received
each_employee_contribution = total_cost / number_of_colleagues
result = each_employee_contribution
return result
|
Claire is baking cupcakes. She needs 2 cups of sugar, 3 cups of flour and 1 stick of butter. A bag of sugar costs $4, a bag of flour costs $5 and a package of butter contains 4 sticks and costs $3. How much will it cost for Claire to bake the cupcakes? | def solve() -> int:
sugar_cost = 4
flour_cost = 5
butter_cost = 3 / 4
total_cost = 2*sugar_cost + 3*flour_cost + butter_cost
result = total_cost
return result
|
A container was filled with 60 liters of water. After 30 liters of water were removed, the container was filled with 45 liters of water. What is the total capacity of the container? | def solve() -> int:
initial_volume = 60
removed = 30
final_volume = 45
capacity = final_volume + removed
result = capacity
return result
|
A triangle has a base of 10 cm and a height of 6 cm. What is the area of the triangle, in cm^2? | def solve() -> int:
base = 10
height = 6
area = 0.5*base*height
result = area
return result
|
A rectangle is twice as long as it is wide. If the perimeter is 120 cm, what is the length of the rectangle? | def solve() -> int:
perimeter = 120
width = perimeter/6
length = width * 2
result = length
return result
|
In a chess tournament, Player A won 3 games, drew 2 games, and lost 1 game. Player B won 4 games and drew 2 games. How many more points did Player B earn than Player A in the tournament? | def solve() -> int:
a_wins = 3
a_draws = 2
a_losses = 1
b_wins = 4
b_draws = 2
a_points = a_wins * 1 + a_draws * 0.5
b_points = b_wins * 1 + b_draws * 0.5
difference = b_points - a_points
result = difference
return result
|
John needs to cover a distance of 400 miles. His car consumes 20gal of fuel per 100 miles and each gallon cost 2 dollars. How much will it cost John in total? | def solve() -> int:
distance = 400
fuel_efficiency = 20
cost_per_gal = 2
total_fuel_cost = (distance // 100) * fuel_efficiency * cost_per_gal
result = total_fuel_cost
return result
|
Amanda and Mike are selling cupcakes at a bake sale. Amanda has sold 28 cupcakes more than Mike when she sells 15 cupcakes. Mike sells 20 cupcakes. How many cupcakes more has Amanda sold than Mike now? | def solve() -> int:
amanda_sold = 0
mike_sold = 0
amanda_sold = 15 + 28
mike_sold = 20
difference = amanda_sold - mike_sold
result = difference
return result
|
If John is twice as heavy as what Samantha weighs and Samantha weights 240 lbs less than Bella's weight. If Bella weighs 480 lbs, what's the total weight of all three? | def solve() -> int:
bella_weight = 480
samantha_weight = bella_weight - 240
john_weight = 2 * samantha_weight
total_weight = bella_weight + samantha_weight + john_weight
result = total_weight
return result
|
A square has sides that measure 6 cm in length. What is its perimeter and area? | def solve() -> int:
side_length = 6
perimeter = 4 * side_length
area = side_length ** 2
result = (perimeter, area)
return result
|
Anna, Bob, and Carl are collecting stamps. Anna has 12 stamps from France, 15 stamps from Germany, and 10 stamps from Japan. Bob has 8 stamps from France, 20 stamps from Germany, and 12 stamps from Japan. Carl has 10 stamps from France, 10 stamps from Germany, and 15 stamps from Japan. How many stamps do they have in t... | def solve() -> int:
france_stamps = 12 + 8 + 10
germany_stamps = 15 + 20 + 10
japan_stamps = 10 + 12 + 15
total_stamps = france_stamps + germany_stamps + japan_stamps
result = total_stamps
return result
|
Tyler wants to buy a new laptop. The laptop costs $1000 and he is offered a discount of 5%. In addition, he wants to buy a carrying case, which costs $50. What will be the total cost of the laptop and carrying case for Tyler? | def solve() -> int:
laptop_cost = 1000
discount = 0.05
carrying_case_cost = 50
discount_amount = laptop_cost * discount
total_cost = laptop_cost - discount_amount + carrying_case_cost
result = total_cost
return result
|
If the area of a square is increased by 250%, what is the percentage increase in the side length of the square? | def solve() -> int:
area_ratio = 2.5
side_ratio = area_ratio ** 0.5
percentage_increase = (side_ratio - 1) * 100
result = int(percentage_increase)
return result
|
Student: In a Grade 6 baking club, the students have to make muffins using different ingredients. The recipe for one batch of muffins requires 2 cups of flour, 1 cup of sugar, 0.5 cup of butter, and 2 eggs. The students make three batches of muffins, but they use different amounts of sugar for each batch. The first bat... | def solve() -> int:
batch1_sugar = 1.2
batch2_sugar = 0.8
batch3_sugar = 1
total_sugar = batch1_sugar + batch2_sugar + batch3_sugar
result = total_sugar / 3
return result
|
Samantha has 125 marbles. This is twice as many marbles as David has and 25 more than the number of marbles that Kevin has. What is the average number of marbles they have? | def solve() -> int:
samantha_marbles = 125
david_marbles = samantha_marbles / 2
kevin_marbles = samantha_marbles - 25
total_marbles = samantha_marbles + david_marbles + kevin_marbles
avg_marbles = total_marbles / 3
result = avg_marbles
return result
|
At a car dealership, a car is being sold for $25,000. The dealership offers a 10% discount on the original price. What is the final price of the car? | def solve() -> int:
original_price = 25000
discount_percent = 0.1
discount_amount = original_price * discount_percent
final_price = original_price - discount_amount
result = final_price
return result
|
Lisa wants to know if she can afford to buy a new laptop. The laptop costs $2,000 and Lisa has $1,000 saved. She can get a loan for the remaining amount at an interest rate of 6% per year for 2 years. How much will Lisa have to pay per month to pay off the loan? | def solve() -> int:
laptop_cost = 2000
savings = 1000
loan_amount = laptop_cost - savings
interest_rate = 0.06
loan_duration = 2
monthly_interest_rate = interest_rate / 12
loan_duration_months = loan_duration * 12
monthly_payment = loan_amount * (monthly_interest_rate * (1 + mo... |
Emily paid $5 for 2 loaves of bread and 1 container of butter. Jake paid $8 for 4 loaves of bread and 2 containers of butter. How much does a container of butter cost? | def solve() -> int:
bread_price = 5 / 2
butter_price = (8 - 4 * bread_price) / 2
result = butter_price
return result
|
Kelly spent $120 on clothes. Each item of clothing cost $15. How many items of clothing did she buy? | def solve() -> int:
total_spent = 120
cost_per_item = 15
num_items = total_spent // cost_per_item
result = num_items
return result
|
Some possible questions and programs are: Leah baked 120 cookies for a bake sale. She sold 25% of them in the morning and 35% of them in the afternoon. She donated the rest of the cookies to a local shelter. How many cookies did Leah donate? | def solve() -> int:
morning_sold = 0.25 * 120
afternoon_sold = 0.35 * 120
remaining = 120 - morning_sold - afternoon_sold
result = remaining
return result
|
Noah has a collection of coins in a jar. He has 20 quarters, 15 dimes, 10 nickels, and 5 pennies. He decides to take out some coins from the jar and count their value. He takes out 8 quarters, 6 dimes, 4 nickels, and 2 pennies. How much money, in dollars, did he take out from the jar? | def solve() -> int:
quarter = 25
dime = 10
nickel = 5
penny = 1
quarters_taken = 8
dimes_taken = 6
nickels_taken = 4
pennies_taken = 2
value_in_cents = quarter * quarters_taken + dime * dimes_taken + nickel * nickels_taken + penny * pennies_taken
value_in_dollars = value_in_cents... |
Student: Ellie had 6 colored pencils left in her box, but she knew she would need more for her drawing. Connor took three-eighths of the 48 colored pencils he had and gave them to Ellie. How many colored pencils does Ellie have after adding Connor's? | def solve() -> int:
ellie = 6
connor = 48
fraction = 3/8
connor_gave = fraction * connor
ellie += connor_gave
result = ellie
return result
|
Aneke needs 8 eggs to make 2 cakes. She made 3 cakes on Monday. On Tuesday, she made 4 times as many cakes as Monday. How many eggs did she use to make all the cakes? | def solve() -> int:
eggs_Monday = 8 * 3
eggs_Tuesday = 8 * 3 * 4
result = eggs_Monday + eggs_Tuesday
return result
|
A baseball hat costs $5, a wiffle ball costs $3, and Laura paid 25% sales tax. How much money did Laura spend? | def solve() -> int:
tax_rate = 0.25
baseball_hat_cost = 5
wiffle_ball_cost = 3
baseball_hat_tax = baseball_hat_cost * tax_rate
wiffle_ball_tax = wiffle_ball_cost * tax_rate
total_cost = baseball_hat_cost + wiffle_ball_cost + baseball_hat_tax + wiffle_ball_tax
re... |
A train travels at a constant speed of 60 kilometers per hour. It leaves Station A at 10:00 AM and arrives at Station B at 11:30 AM. How far apart are Station A and Station B? | def solve() -> int:
speed = 60
departure = 10
arrival = 11.5
travel_time = arrival - departure
distance = speed * travel_time
result = distance
return result
|
Student: Lisa is organizing a fundraiser where she has to accommodate 95 guests. Out of those, 35 guests prefer tea, 3 times the number of tea drinkers are coffee drinkers, and the rest prefer juice. If 5 more juice drinkers are added, how many guests will prefer juice at the event? | def solve() -> int:
tea_drinkers = 35
coffee_drinkers = 3 * tea_drinkers
juice_drinkers = 95 - tea_drinkers - coffee_drinkers
juice_drinkers_after_addition = juice_drinkers + 5
result = juice_drinkers_after_addition
return result
|
A company makes a profit of $10 for each item that they sell. If they sell 500 items, what is their total profit? | def solve() -> int:
profit_per_item = 10
items_sold = 500
total_profit = profit_per_item * items_sold
result = total_profit
return result
|
Emma wants to buy a shirt and a pair of shoes, the original price of the shirt is $35 and the price of the shoes is $65. If there is a 20% discount, what is the total cost for the shirt and shoes after the discount? | def solve() -> int:
shirt_price = 35
shoes_price = 65
discount = 0.20
discounted_amount_shirt = shirt_price*discount
discounted_amount_shoes = shoes_price*discount
total_cost = shirt_price - discounted_amount_shirt + shoes_price - discounted_amount_shoes
result = total_cost
... |
A gardener has 60 strawberry plants. If each plant yields 12 strawberries in a season and she wishes to sell them in packages of 8 strawberries, how many packages of strawberries can she make? | def solve() -> int:
plants = 60
yield_per_plant = 12
total_yield = plants * yield_per_plant
package_size = 8
total_packages = total_yield // package_size
result = total_packages
return result
|
Jessica has $1000 and invests $200 at a 10% annual interest rate. How much money will she have after 3 years? | def solve() -> int:
balance = 1000
interest_rate = 0.1
interest = 200 * interest_rate
balance = balance + interest
balance = balance * (1 + interest_rate) ** 3
result = balance
return result
|
Emily bought a new laptop for $2000 and decide to buy a 5-year protection plan that costs 8% of the cost of the laptop each year. How much did Emily spend in total for the laptop and the protection plan? | def solve() -> int:
emily_laptop_cost = 2000
emily_protection_plan_cost_percentage =.08
emily_years = 5
result = emily_laptop_cost * (1 + emily_protection_plan_cost_percentage * emily_years)
return result
|
Oliver spent 2 hours studying for his first exam. For his second exam, he studied 50% longer than for his first. In total, Oliver spent 6 hours studying for both exams combined. How many hours did he spend studying for the second exam? | def solve() -> int:
exam1 = 2
exam2 = exam1 * 1.5
total_time = exam1 + exam2
difference = 6 - total_time
result = exam2 + difference
return result
|
Lauren has 100 more Pokémon cards than Adam. If Lauren has twice as many Pokémon cards as Zoe, and Adam has half as many cards as Zoe, how many cards does Zoe have? | def solve() -> int:
adam = 0
lauren = adam + 100
zoe = 0
zoe = lauren / 2
adam = zoe / 2
result = zoe
return result
|
If Dylan bought three movie tickets for $11.99 each with a flat $5 processing fee, how much did he pay in total? A toy store has 3 types of action figures. They sell twice as many Spiderman figures as Batman figures, and three times as many Iron Man figures as Superman figures. The Superman figures sell half as much as... | def solve() -> int:
ticket_price = 11.99
num_tickets = 3
processing_fee = 5
total_cost = (ticket_price * num_tickets) + processing_fee
batman_figures = 10
spiderman_figures = 2 * batman_figures
superman_figures = spiderman_figures / 2
ironman_figures = 3 * superman_figures
... |
ome possible new questions are: A rectangular garden is 80 meters long and 50 meters wide. If there are 12 flowers per square meter, how many flowers are there in the garden? | def solve() -> int:
length = 80
width = 50
density = 12
area = length * width
flowers = area * density
result = flowers
return result
|
Student: The sum of four consecutive numbers is 82. Find the smallest of the four numbers. | def solve() -> int:
sum = 82
first_number = sum - 3 * 1
result = first_number
return result
|
Student: John invested $8000 in a bank account that pays 6% interest per year. How much would he get at the end of 5 years? | def solve() -> int:
principal = 8000
interest_rate = 0.06
time = 5
amount = principal * (1 + interest_rate) ** time
result = amount
return result
|
A company makes a profit of 25% on each product it sells. If a product costs $40 before the profit is added, what is the selling price of the product? | def solve() -> int:
cost_price = 40
profit_margin = 0.25
selling_price = cost_price * (1 + profit_margin)
result = selling_price
return result
|
There are 300 liters of juice in 20 bottles. If 7 of the bottles have 12 liters each, how many liters of juice are there in each of the remaining bottles? | def solve() -> int:
juice_12 = 7 * 12
juice_remain = 300 - juice_12
bottles_remain = 20 - 7
juice_per_bottle = juice_remain / bottles_remain
result = juice_per_bottle
return result
|
A truck driver is transporting three times as many oranges as apples. If together they have 78 pieces of fruit, how many oranges and apples does the truck driver have respectively? | def solve() -> int:
Oranges = 0
Apples = 0
Oranges = 58.5
Apples = 19.5
result = (Oranges, Apples)
return result
|
David receives $8 per hour as a handyman and an additional $20 for every job he completes. This week he worked for 25 hours and completed 3 jobs. How much money did he make this week? | def solve() -> int:
hours_worked = 25
hourly_wage = 8
jobs_completed = 3
job_pay = 20
total_earnings = (hours_worked * hourly_wage) + (jobs_completed * job_pay)
result = total_earnings
return result
|
Evan has 15 apples and he wants to make apple pies. Each apple pie requires 3 apples and he has enough dough for 4 pies. How many apples does he need to buy to make 4 pies? | def solve() -> int:
apples = 15
each_pie = 3
pies = 4
needed = each_pie * pies
buy = needed - apples
result = buy
return result
|
If Marly wants to make twice as much soup, how much milk and chicken stock should he add? Assume the same ratio of milk to chicken stock. | def solve() -> int:
milk = 2
chicken_stock = milk*3
pureed_veg = 1
total = (2*milk)+(2*chicken_stock)+2*pureed_veg
result = total
return result
|
The sum of three consecutive even integers is 72. What is the largest of the three integers? | def solve() -> int:
first_even = (72/3)-2
largest_even = first_even + 4
result = largest_even
return result
|
If a company quadruples their profits and divides by 3, then that's 80 less than the original profits. What were the original profits? | def solve() -> int:
original_profits = 0
new_profits = original_profits * 4 / 3
new_profits = new_profits - 80
original_profits = new_profits * 3 / 4
result = original_profits
return result
|
There were 120 students registered for a field trip, but only 90 showed up. What percentage of the students did not show up? | def solve() -> int:
students_not_there = ((120-90)/120)*100
result = round(students_not_there, 2)
return result
|
Rachel worked for 45 hours at $10.50 per hour. She spent $60 on a new haircut. How much money is left? | def solve() -> int:
hours_worked = 45
hourly_rate = 10.50
haircut_cost = 60
total_earnings = hours_worked * hourly_rate
money_left = total_earnings - haircut_cost
result = money_left
return result
|
Student: A triangle has a base of 8 cm and a height of 12 cm. What is the area of the triangle? | def solve() -> int:
base = 8
height = 12
area = 0.5 * base * height
result = area
return result
|
Student: A bus can hold 60 passengers, and a boat can hold 270 passengers. If there are 2970 passengers in total to be transported, how many buses and boat trips will be needed? | def solve() -> int:
bus_capacity = 60
boat_capacity = 270
total_passengers = 2970
num_buses = total_passengers // bus_capacity
num_boats = (total_passengers - (num_buses * bus_capacity)) // boat_capacity
result = num_buses + num_boats
return result
|
Maya's trophy is 10 inches taller than her brother's. If her brother's trophy is 7 inches tall, how tall is Maya's trophy in inches? | def solve() -> int:
brother_trophy_height = 7
mayas_trophy_height = brother_trophy_height + 10
result = mayas_trophy_height
return result
|
A billboard is 30 feet high and 50 feet wide. Find the area of the billboard in square feet. | def solve() -> int:
height = 30
width = 50
area = height * width
result = area
return result
|
The height of a pyramid is 20cm and its base is a square of side 40cm. What is the total area of the four triangles that form the pyramid? | def solve() -> int:
height = 20
base = 40
half_base = base/2
triangle_side = (half_base**2 + height**2)**0.5
triangle_area = 0.5 * half_base * triangle_side
total_area = 4 * triangle_area
result = total_area
return result
|
In a survey, 55% of participants chose red as their favorite color and 30% chose blue. If there were 600 participants, how many chose a color other than red or blue? | def solve() -> int:
participants_chose_red = 0.55 * 600
participants_chose_blue = 0.30 * 600
participants_chose_other = 600 - participants_chose_red - participants_chose_blue
result = participants_chose_other
return result
|
A car traveled 225 miles in 4.5 hours. What was the average speed of the car in miles per hour? | def solve() -> int:
distance = 225
time = 4.5
average_speed = distance / time
result = average_speed
return result
|
Mike spent $852 on a new engine for his car. Brad spent $148 on oil, $25 on tires and $129 on detailing for his car. How many more dollars did Mike spend on his car? | def solve() -> int:
mike_spent = 852
brad_spent = 148 + 25 + 129
difference = mike_spent - brad_spent
result = difference
return result
|
Student: A store sells 3 types of fruits: apples, bananas, and oranges for $0.50, $0.25, and $0.30 per piece respectively. In one day, they sold 100 apples, 75 bananas, and 120 oranges. How much revenue did they make from selling fruits that day? | def solve() -> int:
apples = 100
bananas = 75
oranges = 120
total_fruits = apples + bananas + oranges
cost_apples = apples * 0.50
cost_bananas = bananas * 0.25
cost_oranges = oranges * 0.30
total_cost = cost_apples + cost_bananas + cost_oranges
revenue = total_cost
result = reven... |
Student: On a camping trip, eight people travel 17.7 miles on three different days. On the first day they travel 4.2 miles, on the second day they travel 8.5 miles, and on the third day they travel 4.0 miles. How much farther do they need to travel on the third day to complete the trip? | def solve() -> int:
people = 8
total_miles = 17.7
day1_miles = 4.2
day2_miles = 8.5
day3_miles = 4.0
total_miles_traveled = day1_miles + day2_miles + day3_miles
remaining_miles = total_miles - total_miles_traveled
result = remaining_miles + day3_miles
return result
|
In a school, there are 4 classes of kindergarten, each with 20 students. If each class has 10 girls and 10 boys, what is the total number of girls and boys in the kindergarten? | def solve() -> int:
class_size = 20
num_classes = 4
num_girls = class_size * num_classes * 0.5
num_boys = class_size * num_classes * 0.5
result = num_girls + num_boys
return result
|
Two friends went to a restaurant and the bill came out to be $60. They decided to split the bill equally and also leave a 20% tip on the total amount. How much does each person need to pay? | def solve() -> int:
total_bill = 60
num_of_people = 2
tip_percentage = 20
total_bill_with_tip = total_bill + total_bill * tip_percentage / 100
amount_per_person = total_bill_with_tip / num_of_people
result = round(amount_per_person, 2)
return result
|
haron needs 52 boxes of paper for her project. Each box contains 10 sheets of paper. How many sheets of paper does Sharon need in total? | def solve() -> int:
box_num = 52
sheets_per_box = 10
total_sheets_needed = box_num * sheets_per_box
result = total_sheets_needed
return result
|
Sophie has three times as many stamps as postcards. If she has a total of 60 stamps, how many postcards does she have altogether? | def solve() -> int:
stamps = 60
postcards = stamps / 3
result = postcards
return result
|
Student: There are 56 cookies in one jar and 48 cookies in a second jar. How many cookies are there in total? | def solve() -> int:
jar1 = 56
jar2 = 48
total = jar1 + jar2
result = total
return result
|
Mark prepared berry pies. He ate 1/4 of the first pie and gave 2/3 of the second pie to his grandmother. His sister ate 1/2 of the third pie and gave 1/6 of the fourth pie to their neighbor. There were 9/12 of the fourth pie left. How many pies did Mark prepare? | def solve() -> int:
result = 0
total_pies = 0
pies_consumed = 0
pies_consumed += 0.25
pies_consumed += 0.67
pies_consumed += 0.50
pies_consumed += 0.17
total_pies = 0.75 + pies_consumed
result = total_pies
return result
|
The Cooking School offers 4 beginner cooking classes on weekdays and 2 beginner cooking classes on each day of the weekend. Each cooking class has room for 6 students. How many students can take cooking classes in 3 weeks? | def solve() -> int:
weekdays = 5
weekend_days = 2
classes_per_weekday = 4
classes_per_weekend_day = 2
students_per_class = 6
total_classes = (weekdays * classes_per_weekday) + (weekend_days * classes_per_weekend_day)
total_students = total_classes * students_per_class
total_students... |
Student: Parker copied 12 pages at 4 cents per page. If the tax rate is 8%, how much will Parker have to pay in total? | def solve() -> int:
pages = 12
cost_per_page = 0.04
tax_rate = 0.08
subtotal = pages * cost_per_page
tax = subtotal * tax_rate
total = subtotal + tax
result = total
return result
|
John and James are competing to see who can pick more oranges. James picked twice as many oranges as John. They combined, and they have 240 oranges between them. How many oranges did John pick? | def solve() -> int:
john_oranges = 0
james_oranges = 0
john_oranges = 240 / 3
result = john_oranges
return result
|
John bought two kg of apples for $3. He also bought two kg of oranges for $5. How many dollars did he pay in total? | def solve() -> int:
apples_price = 3 * 2
oranges_price = 5 * 2
total_price = apples_price + oranges_price
result = total_price
return result
|
Bob has 24 marbles and he wants to divide them evenly among his 6 friends. How many marbles would each friend get? | def solve() -> int:
each_friend = 24 // 6
result = each_friend
return result
|
Brad, Jerry, and David are cyclists who practice every Tuesday. Brad rode 16/19 of a 42-kilometer route on one Tuesday. Jerry rode 4/5 of the distance of Brad, and David rode 22/27 of the distance of Brad. How many more kilometers should David ride to cover the same distance as Brad? | def solve() -> int:
n1 = 42
n2 = n1 * 16/19
n3 = n2 * 4/5
n4 = n2 * 22/27
result = n2 - n4
return result
|
Rachel went to the grocery store to buy snacks. Chips cost $2, cookies cost $3, and candy bars cost $1. For every 7 snacks that customers buy, the store offers a $3 discount. Rachel buys 5 chips, 3 cookies, and 8 candy bars. How much will she pay? | def solve() -> int:
chips_cost = 2
cookies_cost = 3
candy_bars_cost = 1
chips_quantity = 5
cookies_quantity = 3
candy_bars_quantity = 8
total_snacks = chips_quantity + cookies_quantity + candy_bars_quantity
discounts = total_snacks // 7
total_cost = (chips_cost * chips_quan... |
Mark goes to the grocery store and buys 3 apples that cost $2 each, 5 oranges that were 30 cents each and 4 strawberries that cost 75 cents each. How much did Mark spend? | def solve() -> int:
apples = 2*3
oranges = 0.3*5
strawberries = 0.75*4
total_cost = apples + oranges + strawberries
result = total_cost
return result
|
Liam and Lucy picked 350 flowers together. Lucy picked 1/5 as many flowers as Liam. How many flowers did Lucy pick? | def solve() -> int:
liam = 0
lucy = 0
liam = 350 * 5/6
lucy = 350 - liam
result = lucy
return result
|
Brad has saved $2000 for his first year of college, but tuition for his college costs $30000. He was awarded a grant that will cover 70% of the remainder of his tuition. How much more money does he need to apply for to receive a loan that will cover his tuition? | def solve() -> int:
tuition = 30000
grant = tuition * (1 - 0.7)
result = grant - 2000
return result
|
Jack scored six more points than Kelly scored. Leo scored eight times as many points as Kelly scored. If Leo scored 32 points, how many points did Jack score? | def solve() -> int:
kelly = 32 // 8
jack = kelly + 6
result = jack
return result
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.