question stringlengths 11 2.89k | code stringlengths 20 7.24k |
|---|---|
Jiho has 5000 MB of cell phone data each month. If he spends 1000 MB on SnapChat and 4/7 of what remain on games, how many MB of data does he have left? | def solve() -> int:
total_data = 5000
snapchat_data = 1000
remain_data = total_data - snapchat_data
games_data = remain_data * (4/7)
result = total_data - snapchat_data - games_data
return result
|
If Laura can knit 4 sweaters in 2 weeks, how many sweaters can she knit in 1 month and 2 days if she takes a 30-minute break after every completed sweater? | def solve() -> int:
sweaters_per_week = 4/2
time_per_sweater = 7*24*60/sweaters_per_week
break_time = 30
time_per_sweater_with_break = time_per_sweater + break_time
total_weeks = 5
total_time = total_weeks * 7 * 24 * 60
total_sweaters = total_time // time_per_sweater_with_break
result =... |
A company offers a 20% discount on all orders over $100. If you buy $130 worth of products, how much will you have to pay? | def solve() -> int:
total_cost = 130*0.8
result = f'<<<{total_cost}>>>'
result = total_cost
return result
|
Student: Leo has $600 in his bank account. He borrowed $100 from his friend and paid him back $120 the next week. Then, he won $200 in a lottery and deposited the money into his bank account. The next week, he withdrew 25% of his bank balance to buy a gift for his sister. How much is in his bank account now? | def solve() -> int:
bank_balance = 600
bank_balance = bank_balance + 20
bank_balance = bank_balance + 200
bank_balance = bank_balance - (bank_balance * 0.25)
result = bank_balance
return result
|
A shirt is available at a store for $17.50. However, Josh has a coupon that offers a 25% discount on his next purchase. If he uses this coupon to purchase the shirt, how much does he save on his purchase? | def solve() -> int:
shirt_price = 17.50
discount_percentage = 25
discount = (discount_percentage / 100) * shirt_price
result = round(discount, 2)
return result
|
There are 64 students in a class. If 12 students are absent, what percentage of students are present? | def solve() -> int:
present_students = 64 - 12
percentage = (present_students/64) * 100
result = percentage
return result
|
A flag is 6 meters long. It tears in half, with one part still on the flagpole while the other part is on the ground. The part on the ground is now 3 meters away from the flagpole base. How far from the flagpole was the tear initially? | def solve() -> int:
flag_length = 6
distance_from_flagpole = 3
initial_distance_from_flagpole = (flag_length - distance_from_flagpole) / 2
result = initial_distance_from_flagpole
return result
|
Max has 18 balloons. He gave 6 to his little brother and then bought 9 more. How many balloons does he have now? | def solve() -> int:
balloons = 18
gave_to_brother = 6
bought_more = 9
balloons -= gave_to_brother
balloons += bought_more
result = balloons
return result
|
A company produces 300 widgets a day. They want to increase this to 400 widgets a day over the next 6 months. By what percentage do they need to increase their daily production to achieve this goal? | def solve() -> int:
current_daily_production = 300
goal_daily_production = 400
increase = goal_daily_production - current_daily_production
percentage_increase = increase / current_daily_production * 100
result = percentage_increase
return result
|
A lemonade stand sells a cup of lemonade for $0.5. The ingredients for making one cup of lemonade cost $0.1. The stand pays $10 for renting a spot in the park for a day. If the stand sells 120 cups of lemonade in a day, how much money does it earn after paying the rent? | def solve() -> int:
cup_cost = 0.1
cup_price = 0.5
cup_num = 120
rent = 10
total_cost = cup_cost * cup_num + rent
total_revenue = cup_price * cup_num
earnings = total_revenue - total_cost
result = earnings
return result
|
Gilbert bought a new gaming console for $400.00, a controller for $25.00 and two game cartridges for $35.00 each. He was offered a 15% discount for buying all three items at the same time. How much will Gilbert pay in total with the discount? | def solve() -> int:
gaming_console_price = 400
controller_price = 25
each_cartridge_price = 35
discount = 0.15
total_amount_paid_without_discount = gaming_console_price + controller_price + (each_cartridge_price * 2)
total_discounted_price = (gaming_console_price + controller_pr... |
A store is offering a 20% discount on a $50 item. What will be the final price of the item after the discount is applied? | def solve() -> int:
original_price = 50
discount_percentage = 20
discount_amount = original_price * (discount_percentage/100)
final_price = original_price - discount_amount
result = final_price
return result
|
Student: What is the next number in the sequence 5, 8, 11, 14,... ? | def solve() -> int:
first_number = 5
common_difference = 3
next_number = first_number + common_difference
result = next_number
return result
|
John owns ten horses. Every day, the number of horses doubles. On the fifth day, he sells three horses. On the seventh day, he buys six more horses. How many horses does he have in total? | def solve() -> int:
horses = 10
horses = horses * 2 ** 5
horses = horses - 3
horses = horses + 6
result = horses
return result
|
On a necklace, the first bead is blue and one fifth of the remaining beads are also blue. Each necklace has 20 beads. Kate makes 10 necklaces. How many blue beads are there? | def solve() -> int:
remaining = 20 - 1
blue = remaining * 1/5
total_blue = 1 + blue
result = total_blue * 10
return result
|
The local office supply store has a sale on pens. If you buy 2 packs of pens, you get 1 pack free. A pack of pens normally costs $3.25. If John wants to buy enough pens so that he has 5 pens for every person in his department (there are 10 people in his department), how much will he spend? | def solve() -> int:
num_people = 10
pens_per_person = 5
price_per_pack = 3.25
pens_per_pack = 12
total_pens_needed = num_people * pens_per_person
total_packs_needed = total_pens_needed // pens_per_pack + 1
total_cost_packs = (total_packs_needed // 2) * 2 * price_per_pack
tot... |
A recipe for apple pie calls for 5 apples per pie. If you have 35 apples, how many pies can you make and how many apples will be left over? | def solve() -> int:
apples = 35
apples_per_pie = 5
pies = apples // apples_per_pie
apples_left = apples % apples_per_pie
result = (pies, apples_left)
return result
|
Emily can knit a sweater in 8 hours. If she needs to knit 3 sweaters, how many hours will it take her? | def solve() -> int:
sweaters_needed = 3
hours_per_sweater = 8
total_hours = sweaters_needed * hours_per_sweater
result = total_hours
return result
|
Jenna has 14 more balloons than Ryan, while Ryan has 9 more balloons than Kate. If Kate has 5 balloons, how many balloons do they have in total? Liam's garden is 50 square meters in area. He plants grass on 12 square meters of the garden. The area of the garden that is not covered in grass is one-third the size of Nath... | def solve() -> int:
kate_balloons = 5
ryan_balloons = kate_balloons + 9
jenna_balloons = ryan_balloons + 14
total_balloons = kate_balloons + ryan_balloons + jenna_balloons
liam_garden_area = 50
grass_area = 12
nathan_garden_area = (liam_garden_area - grass_area) * 3
asha_garden_area... |
Brian wants to buy 9 fruit trees at 25 dollars each. He shares 3 of them with his brother and the remaining are for his backyard. How much money will he spend on fruit trees for his backyard? | def solve() -> int:
trees_total = 9
price_per_tree = 25
shared_trees = 3
backyard_trees = trees_total - shared_trees
money_spent = backyard_trees * price_per_tree
result = money_spent
return result
|
At a bake sale, there are 4 types of cookies for sale: chocolate chip, oatmeal, sugar, and peanut butter. If there are 20 chocolate chip cookies, 15 oatmeal cookies, 10 sugar cookies, and 25 peanut butter cookies for sale, how many cookies in total are at the bake sale? | def solve() -> int:
cookies=[20,15,10,25]
total=sum(cookies)
result=total
return result
|
Ana sells pottery. A mug costs $6 and a plate costs $4. If she sold 10 mugs and 8 plates, what was her profit? Assume that each mug requires $2 of clay and each plate requires $1.5 of clay. | def solve() -> int:
mug_cost = 6
plate_cost = 4
mug_clay = 2
plate_clay = 1.5
mug_sold = 10
plate_sold = 8
total_earnings = mug_cost * mug_sold + plate_cost * plate_sold
total_clay = mug_clay * mug_sold + plate_clay * plate_sold
profit = total_earnings - total_clay ... |
Student: Marilyn needs 6 minutes to process a payment and 4 minutes to mail it. If she needs which processes and mails 40 payments in total, how long will it take her? | def solve() -> int:
num_payments = 40
process_time = 6
mail_time = 4
total_time = num_payments * (process_time + mail_time)
result = total_time
return result
|
The length of one side of a square is 5 meters. What is the area of the square in square centimeters? | def solve() -> int:
side_length_m = 5
side_length_cm = side_length_m * 100
area_cm_sq = side_length_cm ** 2
result = area_cm_sq / 10000
return result
|
Tom buys a new car for $25,000. If he pays half of the cost upfront and the rest through a 5-year payment plan with 4% interest rate, what is the total amount he will pay for the car in 5 years? | def solve() -> int:
car_cost = 25000
upfront_payment = car_cost / 2
remaining_payment = car_cost - upfront_payment
interest_rate = 0.04
payment_years = 5
monthly_interest_rate = interest_rate / 12
total_months = payment_years * 12
monthly_payment = remaining_payment * (monthly_... |
Haily went to the salon and spent $50 on her hair, nails, and facial cleaning. If the price of the facial cleaning was twice the price of the nails, and the price of the haircut was $10 less than the nails, how much did she spend on each service? | def solve() -> int:
price_fc = 0
price_n = 0
price_h = 0
total = 50
result = (price_fc, price_n, price_h)
return result
|
Student: Dennis wants to build a fence for his garden. The fence requires 45 posts and a board every 6 feet of the fence. How many boards does Dennis need to buy if the the total length of the fence is 150 ft? | def solve() -> int:
posts = 45
length = 150
board_interval = 6
total_boards = (length // board_interval) + 1
result = total_boards
return result
|
Student: Ann has 17 CDs. She bought 2 CDs last week and 3 this week. How many CDs does she have now? | def solve() -> int:
cd_original = 17
cd_last_week = 2
cd_this_week = 3
cd_now = cd_original + cd_last_week + cd_this_week
result = cd_now
return result
|
Student: In a class of 24 students, 5/6 of the girls like strawberry ice cream and 1/3 of the boys do too. There are equal number of boys and girls in the class. What percentage of the class likes strawberry ice cream? | def solve() -> int:
girls = 24 // 2
boys = 24 // 2
girls_like_strawberry = 5 * girls // 6
boys_like_strawberry = boys // 3
total_like_strawberry = girls_like_strawberry + boys_like_strawberry
percentage_like_strawberry = total_like_strawberry / 24 * 100
result = percentage_like_strawberry
... |
A hotel has 200 rooms. A group of 50 tourists checks in, and two weeks later, 30 tourists check out. One month later, 60 more tourists check out. How many tourists are still staying at the hotel? | def solve() -> int:
rooms = 200
tourists_check_in = 50
tourists_check_out_1 = 30
tourists_check_out_2 = 60
tourists_staying_1 = tourists_check_in - tourists_check_out_1
tourists_staying_2 = tourists_staying_1 - tourists_check_out_2
tourists_staying = tourists_staying_2
... |
The sum of three consecutive integers is 57. What is the largest of the three integers? | def solve() -> int:
largest = 20
result = largest
return result
|
Student: A bag contained 24 marbles, 8 of which were red and the rest were blue. Two marbles were drawn at random without replacement. What was the probability that both marbles were red? | def solve() -> int:
total_marbles = 24
red_marbles = 8
prob_red = red_marbles / total_marbles
prob_second_red = (red_marbles - 1) / (total_marbles - 1)
prob_two_red = prob_red * prob_second_red
result = prob_two_red
return result
|
On Monday, a store sold 42 umbrellas. On Tuesday, they sold 8 fewer umbrellas than Monday. How many umbrellas did they sell in total on the two days? | def solve() -> int:
umbrella_monday = 42
umbrella_tuesday = umbrella_monday - 8
total_umbrella = umbrella_monday + umbrella_tuesday
result = total_umbrella
return result
|
Student: A person deposits $500 in a bank account which pays an annual interest rate of 5%. What is the interest earned after 1 year? | def solve() -> int:
deposit = 500
interest_rate = 0.05
interest_earned = deposit * interest_rate
result = interest_earned
return result
|
A company was founded in 1995 and plans to celebrate its 35th anniversary. What year did the celebration occur? | def solve() -> int:
years_to_anniversary = 35
celebration_year = 1995 + years_to_anniversary
result = celebration_year
return result
|
Mark drove North for 10 miles, then turned East and drove for 2 more miles than the distance he took to travel to the North. If he then turned South and drove three times the distance he had driven to the East, calculate the total distance his journey took. | def solve() -> int:
distance_north = 10
distance_east = distance_north + 2
distance_south = distance_east * 3
total_distance = distance_north + distance_east + distance_south
result = total_distance
return result
|
Samantha gets $10 every two weeks for cleaning the house. She saves 25% of it and spends the rest on books. How much money will she have saved after six months? | def solve() -> int:
weeks_in_six_months = 6 * 4
money_per_week = 10
total_money = weeks_in_six_months * money_per_week
saved_money = total_money * 0.25
result = saved_money
return result
|
Alex and his family are on a road trip. If they drove a total of 620 miles in 4 days, how many miles did they drive per day? | def solve() -> int:
total_miles = 620
num_days = 4
miles_per_day = total_miles / num_days
result = miles_per_day
return result
|
Alex wants to buy notebooks for all the 70 students in his class. The class has twice as many girls as boys. There are also 5 non-binary students. If there are 20 boys, how many girls are there? | def solve() -> int:
boys = 20
non_binary = 5
total_students = boys + non_binary
girls = total_students * 2 - boys
result = girls
return result
|
The sum of 5 consecutive odd numbers is 105. What are the numbers? | def solve() -> int:
first_odd = 17
second_odd = first_odd+2
third_odd = second_odd+2
fourth_odd = third_odd+2
fifth_odd = fourth_odd+2
while first_odd+second_odd+third_odd+fourth_odd+fifth_odd!= 105:
first_odd += 2
second_odd += 2
third_odd += 2
fourth_odd += 2
... |
Lisa sold 15 necklaces for $12 each and 10 bracelets for $8 each at a craft fair. She paid $25 for the booth rental and $10 for the materials. How much profit did she make? | def solve() -> int:
revenue = 15 * 12 + 10 * 8
cost = 25 + 10
profit = revenue - cost
result = profit
return result
|
At a bakery, Sarah purchased 5 cupcakes and 1 loaf of bread. If each cupcake costs $2 and a loaf of bread costs the same as 5 cupcakes, how much is Sarah's change if she gave the cashier $20? | def solve() -> int:
cupcake_cost = 2
bread_cost = 5 * cupcake_cost
total_cost = 5 * cupcake_cost + bread_cost
change = 20 - total_cost
result = change
return result
|
There are two circular fields of different sizes on a farm, one with a radius of 40ft and the other with a radius of 50ft. John is using the smaller circular field to grow corn and wants to use the larger one for growing vegetables. However, he has to first put up a fence around the vegetable field. Find out how much e... | def solve() -> int:
corn_field_radius = 40
veg_field_radius = 50
corn_field_circumference = 2*3.14*corn_field_radius
extra_fence_required = (corn_field_circumference) - (2*3.14*veg_field_radius)
result = extra_fence_required
return result
|
If a cupcake shop has 36 cupcakes and needs to divide them into 9 even packages, how many cupcakes will there be in each package? | def solve() -> int:
init_cupcakes = 36
num_packages = 9
cupcakes_needed = init_cupcakes // num_packages
remainder_cupcakes = init_cupcakes % num_packages
result = cupcakes_needed
return result
|
Sarah started swimming when she was 13. She swims 1 mile every day until she turns 18. How many miles did Sarah swim during her 5 years of swimming? | def solve() -> int:
start_age = 13
end_age = 18
years_swimming = end_age - start_age
miles_per_day = 1
total_miles_swam = years_swimming * 365 * miles_per_day
result = total_miles_swam
return result
|
A store has 200 shirts and they want to sell them all within 4 days. If they sell equal number of shirts each day, how many shirts will they sell each day? | def solve() -> int:
shirts = 200
days = 4
per_day = shirts / days
result = per_day
return result
|
Student: Jeff is installing a fence around his yard. There is a total of 40 feet of fencing. How many sections of equal size can Jeff make with the fencing? | def solve() -> int:
fence_length = 40
section_size = 5
num_sections = fence_length // section_size
result = num_sections
return result
|
Student: A bucket contained 21 black marbles, 8 red marbles and 7 white marbles. How many marbles are there in the bucket? | def solve() -> int:
black_marbles = 21
red_marbles = 8
white_marbles = 7
total_marbles = black_marbles + red_marbles + white_marbles
result = total_marbles
return result
|
Charles had 9 rabbits in his farm, but he lost 2 and received 6 more rabbits from his neighbor. How many rabbits does he have now? | def solve() -> int:
rabbits = 9
lost_rabbits = 2
received_rabbits = 6
rabbits_updated = rabbits - lost_rabbits + received_rabbits
result = rabbits_updated
return result
|
Student: Ben's dad bought 2 boxes of pencils, each containing 24 pencils. He gave 9 pencils to Ben and 7 pencils to Ben's sister. He then bought another box of pencils, containing 18 pencils. How many pencils does he have left? | def solve() -> int:
box1 = 24
box2 = 24
ben = 9
sister = 7
box3 = 18
left = box1 + box2 + box3 - ben - sister
result = left
return result
|
John needs to sleep at least 7 hours each day for 3 days to overcome his jet lag. On the first day, he slept 3 hours. If he sleeps twice as long each day as the previous day, how many hours will he have slept by the end of the week? | def solve() -> int:
days = 7
hours_slept = 3
total_hours_slept = hours_slept
for i in range(1, days):
hours_slept *= 2
total_hours_slept += hours_slept
result = total_hours_slept
return result
|
Grace and Lily share a dessert in such a way that Grace takes 25% and Lily takes the rest. If Lily's share is $7.50, what was the original cost of the dessert? | def solve() -> int:
lily_share = 7.50
grace_share = lily_share / 0.75
original_cost = grace_share + lily_share
result = original_cost
return result
|
Joey only drinks soda that contains caffeine. On his first glass, there were 20 mg of caffeine. On the second glass, there were 25 mg of caffeine. On his third and fourth glass, there were 15 mg of caffeine. On his fifth glass, there were only 10Jared purchased 5 pens and 2 pencils for a total of $11. If a pen costs $2... | def solve() -> int:
glass1 = 20
glass2 = 25
glass3 = 15
glass4 = 15
glass5 = 10
total_caffeine = glass1 + glass2 + glass3 + glass4 + glass5
num_pens = 5
num_pencils = 2
total_cost = 11
pen_cost = 2
pencil_cost = (total_cost - (num_pens * pen_cost)) / num_pencil... |
Student: A factory use two types of metals to make a product, Aluminum and Copper. If one kg of Aluminum cost $4.50 and a kilogram of Copper cost $3.25, what will a product with two kg of Aluminum and 0.5 kg of Copper cost? | def solve() -> int:
aluminum_cost = 4.50
copper_cost = 3.25
aluminum_weight = 2
copper_weight = 0.5
total_cost = (aluminum_cost * aluminum_weight) + (copper_cost * copper_weight)
result = total_cost
return result
|
Jack bought 4 packs of juice, each containing 6 bottles. He drank 2 bottles every day for 9 days. How many bottles of juice did Jack have left? | def solve() -> int:
total_bottles = 4 * 6
drank_bottles = 2 * 9
left_bottles = total_bottles - drank_bottles
result = left_bottles
return result
|
A small business wants to sell 500 shirts. They have 6 colors of shirts in stock, and want to distribute them evenly among all colors. However, the supplier can only provide 375 shirts. How many shirts will they need to order for each color? | def solve() -> int:
desired_quantity = 500
num_colors = 6
available_quantity = 375
equal_distribution = desired_quantity // num_colors
remaining_quantity = desired_quantity - (equal_distribution * num_colors)
additional_quantity = available_quantity - (equal_distribution * num_colors)
extra_... |
Student: In a school, the ratio of boys to girls is 3:5. If there are 120 more girls than boys, how many girls are there in the school? | def solve() -> int:
boys = 3
girls = 5
diff = girls - boys
total_parts = boys + girls
one_part = diff / 2
num_boys = one_part * boys
num_girls = num_boys + diff
result = num_girls
return result
|
Tom, Dan, and Alex participated in a competition and got 130 points in total. Dan got twice as many points as Tom did and Alex got 5 points more than Dan. How many points did Tom get? | def solve() -> int:
total_points = 130
dan_points = total_points / (2+1+1)
tom_points = dan_points / 2
result = tom_points
return result
|
Student: A rectangle has a length of 10 cm and a width of 5 cm. What is the perimeter and area of the rectangle? | def solve() -> int:
length = 10
width = 5
perimeter = 2 * (length + width)
area = length * width
result = (perimeter, area)
return result
|
If Sam earns $15 per hour and works for 8 hours a day, how much will he earn in total after working for 5 days? | def solve() -> int:
def total_earnings(wage, hours, days):
total_earnings = wage * hours * days
return total_earnings
result = total_earnings(15, 8, 5)
return result
|
A bowl of 12 fruit had been sitting outside for hours and had started to rot. For every four fruit that rot, the remaining fruit rot three times faster than the previous ones. How many times faster than the first fruit does the last fruit rot? | def solve() -> int:
total_fruit = 12
rot_fruit = total_fruit // 4
remaining_fruit = total_fruit - rot_fruit
first_fruit_rot_speed = 1
last_fruit_rot_speed = first_fruit_rot_speed * (3 ** rot_fruit)
ratio = last_fruit_rot_speed / first_fruit_rot_speed
result = ra... |
Lisa is making bracelets for her friends. She has 9 beads of each color: red, blue, green, yellow, and purple. She wants to make each bracelet with 6 beads, using 2 beads of each color. How many bracelets can Lisa make? | def solve() -> int:
beads = 9
bracelet = 6
bracelets = min(beads // 2, beads // 2, beads // 2, beads // 2, beads // 2)
result = bracelets
return result
|
Ana and her brother need to buy 3 jewelries with a certain fixed amount of money. The cost of the first jewelry is $15.50, the second is double the cost of the first one and the third is three times the cost of the first one. How much money are they left with if they have $103 in total? | def solve() -> int:
jewelry1_cost = 15.50
jewelry2_cost = jewelry1_cost * 2
jewelry3_cost = jewelry1_cost * 3
total_cost = jewelry1_cost + jewelry2_cost + jewelry3_cost
remaining_money = 103 - total_cost
result = remaining_money
return result
|
John is throwing a barbecue for his coworkers. He invites 35 people. Half of the guests bring their own meat to grill. He plans to serve 5 different types of salads. If he uses a new plate for every salad, how many plates does he need in total for his guests? | def solve() -> int:
num_guests = 35
num_bring_meat = num_guests / 2
num_salads = 5
num_plates = num_guests + num_bring_meat + num_salads
result = num_plates
return result
|
Wilfred has $7.88 and he needs to buy candy that cost $1.25 each. How many pieces of candy can Wilfred buy? | def solve() -> int:
money = 7.88
cost_each = 1.25
num_candy = money // cost_each
result = 6.3
return result
|
Maya is a pizza chef. She makes an average of 50 pizzas every day. Every Monday, her pizza orders are about 15% higher than the daily average. How many pizzas does she make in a week if the restaurant is open from Tuesday to Sunday? | def solve() -> int:
daily_average = 50
monday_increase = 0.15
monday_pizzas = daily_average * (1 + monday_increase)
other_days_pizzas = daily_average * 6
total_pizzas = monday_pizzas + other_days_pizzas
result = total_pizzas
return result
|
Student: Leo buys 3 packs of candy. Each pack contains 12 pieces of candy. He eats 2 pieces of candy a day. How many days will it take him to finish all the candy? | def solve() -> int:
packs = 3
pieces_per_pack = 12
pieces_eaten_per_day = 2
total_pieces = packs * pieces_per_pack
days = total_pieces / pieces_eaten_per_day
result = days
return result
|
A rectangle has a length of 7 cm and a width of 3 cm. What is the perimeter of the rectangle? | def solve() -> int:
length = 7
width = 3
perimeter = 2 * length + 2 * width
result = perimeter
return result
|
A lamp uses 2 watts of power per minute. After 30 minutes, the power consumption increases to 4 watts per minute. Twenty minutes later, the bulb is replaced and only 1 watt per minute is used. How many watts were consumed in total? | def solve() -> int:
power1 = 2
time1 = 30
power2 = 1
time2 = 20
power3 = 4
time3 = 20
total_power = (power1 * time1) + (power3 * time3) + (power2 * time2)
result = total_power
return result
|
Rachel and Michael order pizzas for $7, garlic bread for $3, and 4 cans of soda for $1.50 each. The tax is $3. Later, Rachel decides to order 2 more cans of soda. How much change should they get from $25? | def solve() -> int:
pizza_price = 7
garlic_bread_price = 3
soda_price = 1.5
num_sodas = 4
tax = 3
extra_sodas = 2
total_cost = pizza_price + garlic_bread_price + (num_sodas * soda_price) + tax
total_cost += extra_sodas * soda_price
change = 25 - total_cost
result =... |
In a bike race between three friends, Jake, Emily, and Max, Jake finished in 15 minutes. Emily took 8 more minutes to finish the race than Jake. If Max is five times slower than Jake, how long did it take him to finish the race? | def solve() -> int:
jake_time = 15
emily_time = jake_time + 8
max_speed = 5
max_time = jake_time * max_speed
result = max_time
return result
|
Carter and his friend Tyler are playing basketball. On a particular day, Carter scored 18 fewer points than Tyler, who scored 60 points. The next day, Tyler scored 1/7 of the points he scored the previous day, while Carter scored half the points he scored on the first day. If they scored the same number of points on th... | def solve() -> int:
tyler_score = 60
carter_score = tyler_score - 18
tyler_score_second_day = tyler_score / 7
carter_score_second_day = carter_score / 2
tyler_score_third_day = carter_score
carter_score_third_day = carter_score
total_score = tyler_score + carter_score + tyler_... |
Zack bought 3 candy bars for $0.50 each. He also bought 5 gumballs for $0.25 each. How much money did Zack spend in total? | def solve() -> int:
candy_bars = 3
candy_bar_price = 0.50
gumballs = 5
gumball_price = 0.25
total_cost = (candy_bars * candy_bar_price) + (gumballs * gumball_price)
result = total_cost
return result
|
Ben runs 3 kilometers every day for 5 days. How many meters does he run in total? If he increases his daily distance by 500 meters every week, how many kilometers will he run in the fourth week? | def solve() -> int:
daily_distance = 3
days = 5
distance_in_meters = daily_distance * 1000
total_distance = distance_in_meters * days
increase = 500
fourth_week_distance = daily_distance + increase * 3 / 1000
fourth_week_total = fourth_week_distance * days
result = fourth_week_total
... |
A store is having a sale of 25% off on all items. If you buy an item originally priced at $40, how much would it cost after the discount is applied? | def solve() -> int:
original_price = 40
discount = 25
discount_amount = original_price * discount / 100
final_price = original_price - discount_amount
result = final_price
return result
|
Student: A train travels 300 miles in 5 hours. What is the speed of the train in miles per hour (mph)? | def solve() -> int:
distance = 300
time = 5
speed = distance / time
result = speed
return result
|
Alex borrowed money from his cousin. He promised to pay it back in 9 months including an additional 6% of the money he borrowed. If he pays $50 per month, how much money did he borrow? | def solve() -> int:
borrowed_money = 0
interest_rate = 6 / 100
monthly_payment = 50
total_payment = 9 * monthly_payment
borrowed_money = total_payment / (1 + interest_rate)
result = borrowed_money
return result
|
Mike is planning a road trip and will drive a total of 1200 miles. He plans to drive 40% of the trip on the first day and 60% on the second day. How many miles will he drive on the second day? | def solve() -> int:
total = 1200
day1 = total * 0.40
day2 = total * 0.60
result = day2
return result
|
Possible questions and programs: Ming bought 80 stickers and gave 15% of them to his friends. How many stickers did he keep for himself? | def solve() -> int:
stickers_given = 80 * 0.15
stickers_kept = 80 - stickers_given
result = stickers_kept
return result
|
The Nguyen family went shopping and bought 12 pounds of apples, 8 pounds of oranges, and 6 pounds of bananas. The apples cost $1.5 per pound, the oranges cost $2 per pound, and the bananas cost $0.75 per pound. They also used a coupon that gave them a 10% discount on the total bill. How much did they pay for the fruits... | def solve() -> int:
apples = 12
apples_price = 1.5
oranges = 8
oranges_price = 2
bananas = 6
bananas_price = 0.75
total_cost = apples * apples_price + oranges * oranges_price + bananas * bananas_price
discount = total_cost * 0.1
final_amount = total_cost - discount
... |
A school has a total of 3000 students, with 1200 boys and the rest girls. What is the percentage of girls in the school? | def solve() -> int:
total_students = 3000
boys = 1200
girls = total_students - boys
percentage_girls = (girls / total_students) * 100
result = percentage_girls
return result
|
Student: A train travels 60 km/h for the first half of the journey and then slows down to 40 km/h for the second half of the journey. The total time it takes to travel the entire journey is 5 hours. What is the total distance traveled? | def solve() -> int:
speed1 = 60
speed2 = 40
time = 5
distance1 = speed1 * (time / 2)
distance2 = speed2 * (time / 2)
result = distance1 + distance2
return result
|
Student: A car dealer offers a financing option for a new car costing $20,000. The terms are a down payment of $5,000 and monthly payments of $500 for the next 3 years. What is the total cost of the car with interest if the financing rate is 4.5%? | def solve() -> int:
car_cost = 20000
down_payment = 5000
monthly_payment = 500
financing_rate = 0.045
num_years = 3
total_cost = car_cost - down_payment + (monthly_payment * num_years * (1 + financing_rate))
result = total_cost
return result
|
Samantha wants to buy 3 beds that cost $800 each with a 15% discount. She also wants to buy 6 pillows that cost $50 each with a 15% discount. How much money will Samantha have to spend in total after the discount? | def solve() -> int:
bed_price = 800
pillow_price = 50
discount = 0.15
bed_discount = bed_price * discount
bed_price_after_discount = bed_price - bed_discount
total_bed_cost = bed_price_after_discount * 3
pillow_discount = pillow_price * discount
pillow_price_after_discount = pi... |
Becca has 600 milliliters of water in a jug. She pours out 20% of the water. How many milliliters of water are left in the jug? | def solve() -> int:
x = 480
result = x
return result
|
am's mom sent him to the store to buy 3 sandwiches that she needs for work the next day. Each sandwich costs $4.50. How much should Sam expect to spend? | def solve() -> int:
price_per_sandwich = 4.50
num_sandwiches = 3
total_cost = price_per_sandwich*num_sandwiches
result = total_cost
return result
|
A store sells shirts for $25 each and makes a profit of $200 on shirt sales. If each shirt costs $10 to make, how many shirts did they sell? | def solve() -> int:
shirt_cost = 10
shirt_sell_price = 25
profit = 200
shirts_sold = profit / (shirt_sell_price - shirt_cost)
result = shirts_sold
return result
|
Mike can lift a heavier weight than anyone in his weightlifting class. In fact, he can lift 1.8 times the average weight lifted by the next three strongest weightlifters. If the next three strongest weightlifters can lift 80 kg, 90 kg, and 100 kg, how much weight can Mike lift? | def solve() -> int:
average_weight_of_others = (80 + 90 + 100) / 3
mike_weight = 1.8 * average_weight_of_others
result = round(mike_weight, 2)
return result
|
Jack's salary is $3000 plus 15% commission of his sales. If he sold $20,000 worth of goods, what is his total compensation? | def solve() -> int:
salary = 3000
commission_rate = 0.15
sales = 20000
commission = commission_rate * sales
total_compensation = salary + commission
result = total_compensation
return result
|
Student: The manager of a small store measured the length of the shelf space and found it to be 8 meters. If the shelf space is 2 meters longer than the combination of the other two shelves, how long are the other two shelves? | def solve() -> int:
shelf_space = 8
other_two_shelves = shelf_space - 2
result = other_two_shelves
return result
|
A car travels at 50 miles per hour. How long will it take to travel a distance of 150 miles? | def solve() -> int:
speed = 50
distance = 150
time = distance / speed
result = time
return result
|
Lily has a jar of coins that contains 25 pennies, 10 nickels, 15 dimes, and 5 quarters. She randomly picks one coin from the jar and puts it in her pocket. Then she picks another coin from the jar and puts it in her pocket. What is the probability that both coins are quarters? | def solve() -> int:
total_coins = 25 + 10 + 15 + 5
prob_quarter_1 = 5 / 55
prob_quarter_2 = 4 / 54
prob_both_quarters = prob_quarter_1 * prob_quarter_2
result = prob_both_quarters
return result
|
If John were to double his age, he would be the same age as his father. When John was born, his father was 36 years old. What is the sum of their current ages? | def solve() -> int:
john_age = 0
father_age = 36
john_age = father_age / 2
sum_of_ages = john_age + father_age
result = sum_of_ages
return result
|
A rectangular garden has length 8 meters and width 5 meters. What is the area of the garden? | def solve() -> int:
length = 8
width = 5
area = length * width
result = area
return result
|
Tim has $400. He spends $150 on clothes and $75 on shoes. He also saves 25% of what is left. How much money does he have left after saving? | def solve() -> int:
money = 400
clothes = 150
shoes = 75
remaining_money = money - clothes - shoes
saving = remaining_money * 0.25
remaining_money_after_saving = remaining_money - saving
result = remaining_money_after_saving
return result
|
A company earned $4500 in revenue last month. After paying $1200 in expenses, what was the company's profit? | def solve() -> int:
revenue = 4500
expenses = 1200
profit = revenue - expenses
result = profit
return result
|
Mia makes 8 pizzas every week. If Mia shares the pizzas equally among 4 colleagues, how many pizzas does each person get? | def solve() -> int:
pizzas_per_week = 8
colleagues = 4
pizzas_per_person = pizzas_per_week / colleagues
result = pizzas_per_person
return result
|
John had 24 toy cars. He gave 8 cars to Mike and 6 cars to his sister. How many toy cars does John have now? | def solve() -> int:
carsJohn = 24
carsMike = 8
carsSister = 6
carsJohn -= carsMike
carsJohn -= carsSister
result = carsJohn
return result
|
A recipe requires 2 1/2 cups of flour. If you want to make 6 batches of this recipe, how many cups of flour will you need? | def solve() -> int:
rec_flour = 2.5
batches = 6
total_flour = rec_flour * batches
result = total_flour
return result
|
At the start of the school assembly, there were 1000 students. Before the assembly ended, one-fourth of the girls and one-sixth of the boys left early. If there were 400 boys at the assembly, how many students remained until the end? | def solve() -> int:
boys = 400
girls = 1000 - boys
girls_left = girls / 4
boys_left = boys / 6
students_left = boys + girls - (girls_left + boys_left)
result = students_left
return result
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.