id stringlengths 23 26 | text stringlengths 20 1.37k | format stringclasses 2
values | messages listlengths 2 4 ⌀ | family stringclasses 1
value | sub stringclasses 3
values | variant stringclasses 1
value | variant_of stringclasses 0
values | generator stringclasses 1
value | sources listlengths 0 0 | source_ids listlengths 0 0 | n_tokens_alea int64 8 494 | meta stringlengths 47 170 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
nlprog_det-setting-0045720 | A count moves from 1,200 to 1,500. By what percent did it change (use a minus sign for a drop)?
Python, step by step:
```python
old = 1200
new = 1500
change = (new - old) / old * 100 # 25.0
print(round(change))
```
What it prints: 25
It changed by 25%. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 101 | {"gold": "25", "printed": "25", "notation": null} |
nlprog_det-setting-0045721 | <|start|><|user|>
How many minutes pass from 8:41 AM to 9:02 AM on the same day?<|eot|>
<|assistant|>
21 minutes pass.<|eot|>
<|end|> | chat | [
{
"role": "user",
"content": "How many minutes pass from 8:41 AM to 9:02 AM on the same day?"
},
{
"role": "assistant",
"content": "21 minutes pass."
}
] | nlprog_det | setting | original | null | deterministic | [] | [] | 31 | {"gold": "21", "printed": "21", "notation": null} |
nlprog_det-setting-0045722 | <|start|><|user|>
A court charges $15 per request plus $0.10 per page after the first 20 pages. What does a 96-page copy cost?<|eot|>
<|assistant|>
```python
pages = 96
base = 15
per_page = 0.1
free_pages = 20
cost = base + max(0, pages - free_pages) * per_page # 22.6
print(f"{cost:.2f}")
```
(Execution result: 22.60)... | chat | [
{
"role": "user",
"content": "A court charges $15 per request plus $0.10 per page after the first 20 pages. What does a 96-page copy cost?"
},
{
"role": "assistant",
"content": "```python\npages = 96\nbase = 15\nper_page = 0.1\nfree_pages = 20\ncost = base + max(0, pages - free_pages) * per_page... | nlprog_det | setting | original | null | deterministic | [] | [] | 134 | {"gold": "22.60", "printed": "22.60", "notation": null} |
nlprog_det-setting-0045725 | A claim accrued on February 11, 2017. The limitations period is 2 years. On what date does it expire?
Here's the code.
```python
from datetime import date
accrued = date(2017, 2, 11) # datetime.date(2017, 2, 11)
years = 2
expires = accrued.replace(year=accrued.year + years) # datetime.date(2019, 2, 11)
print(expires... | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 152 | {"gold": "2019-02-11", "printed": "2019-02-11", "notation": null} |
nlprog_det-setting-0045726 | <|start|><|system|>
You check calculations for an accounting team.<|eot|>
<|user|>
A meal costs $119.49. How much is a 25% tip?<|eot|>
<|assistant|>
bill = 119.49
tip_rate = 25 / 100 # 0.25
tip = bill * tip_rate # 29.8725
print(f"{tip:.2f}")
When run, it prints: 29.87
The tip is $29.87.<|eot|>
<|end|... | chat | [
{
"role": "system",
"content": "You check calculations for an accounting team."
},
{
"role": "user",
"content": "A meal costs $119.49. How much is a 25% tip?"
},
{
"role": "assistant",
"content": " bill = 119.49\n tip_rate = 25 / 100 # 0.25\n tip = bill * tip_rate # 29.872... | nlprog_det | setting | original | null | deterministic | [] | [] | 106 | {"gold": "29.87", "printed": "29.87", "notation": null} |
nlprog_det-setting-0045727 | <|start|><|system|>
You are an assistant for a small office.<|eot|>
<|user|>
Express 104 hours in days and hours.<|eot|>
<|assistant|>
```python
hours = 104
days, rest = divmod(hours, 24)
print(f"{days} days and {rest} hours")
```
On running, it outputs 4 days and 8 hours.
104 hours is 4 days and 8 hours.<|eot|>
<|end... | chat | [
{
"role": "system",
"content": "You are an assistant for a small office."
},
{
"role": "user",
"content": "Express 104 hours in days and hours."
},
{
"role": "assistant",
"content": "```python\nhours = 104\ndays, rest = divmod(hours, 24)\nprint(f\"{days} days and {rest} hours\")\n```... | nlprog_det | setting | original | null | deterministic | [] | [] | 101 | {"gold": "4 days and 8 hours", "printed": "4 days and 8 hours", "notation": null} |
nlprog_det-setting-0045728 | Attendance was 181 out of 200. Express it as a percent.
A short script:
```python
present = 181
total = 200
percent = present / total * 100 # 90.5
print(round(percent, 1))
```
The interpreter prints: 90.5
Attendance was 90.5%. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 86 | {"gold": "90.5", "printed": "90.5", "notation": null} |
nlprog_det-setting-0045729 | <|start|><|user|>
A count moves from 2,000 to 3,000. By what percent did it change (use a minus sign for a drop)?<|eot|>
<|assistant|>
```python
old = 2000
new = 3000
change = (new - old) / old * 100 # 50.0
print(round(change))
```
# program output: 50
The change is 50%.<|eot|>
<|end|> | chat | [
{
"role": "user",
"content": "A count moves from 2,000 to 3,000. By what percent did it change (use a minus sign for a drop)?"
},
{
"role": "assistant",
"content": "```python\nold = 2000\nnew = 3000\nchange = (new - old) / old * 100 # 50.0\nprint(round(change))\n```\n# program output: 50\n\nThe... | nlprog_det | setting | original | null | deterministic | [] | [] | 94 | {"gold": "50", "printed": "50", "notation": null} |
nlprog_det-setting-0045730 | A lease runs for 24 months at $1,200 per month. How much rent is paid over the whole term?
As a program:
```python
monthly_rent = 1200
months = 24
total = monthly_rent * months # 28800
print(total)
```
The run gives 28800, as expected.
In total, $28,800 is paid. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 97 | {"gold": "28800", "printed": "28800", "notation": null} |
nlprog_det-setting-0045731 | Convert 1 h 24 min (the length of a deposition) to minutes.
Written as code:
```python
hours = 1
minutes = 24
total_minutes = hours * 60 + minutes # 84
print(total_minutes)
```
What it prints: 84
The deposition lasted 84 minutes. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 86 | {"gold": "84", "printed": "84", "notation": null} |
nlprog_det-setting-0045732 | <|start|><|user|>
A 1026-page report must be reviewed in 19 days. How many pages a day is that, evenly?<|eot|>
<|assistant|>
```python
pages = 1026
days = 19
per_day = pages // days
print(per_day)
```
Executing it gives 54.
54 pages a day.<|eot|>
<|end|> | chat | [
{
"role": "user",
"content": "A 1026-page report must be reviewed in 19 days. How many pages a day is that, evenly?"
},
{
"role": "assistant",
"content": "```python\npages = 1026\ndays = 19\nper_day = pages // days\nprint(per_day)\n```\nExecuting it gives 54.\n\n54 pages a day."
}
] | nlprog_det | setting | original | null | deterministic | [] | [] | 84 | {"gold": "54", "printed": "54", "notation": null} |
nlprog_det-setting-0045733 | $5,000 is invested at 4% compounded yearly. What is it worth after 4 years?
Here is a short program for it.
```python
principal = 5000
rate = 4 / 100 # 0.04
years = 4
value = principal * (1 + rate) ** years # 5849.292800000001
print(f"{value:.2f}")
```
Printed:
5849.29
The balance is $5,849.29. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 126 | {"gold": "5849.29", "printed": "5849.29", "notation": null} |
nlprog_det-setting-0045735 | <|start|><|user|>
Filing fees are $90 per document. What do 3 filings cost?<|eot|>
<|assistant|>
```python
fee = 90
filings = 3
total = fee * filings # 270
print(total)
```
Printed — 270
The filings cost $270 in all.<|eot|>
<|end|> | chat | [
{
"role": "user",
"content": "Filing fees are $90 per document. What do 3 filings cost?"
},
{
"role": "assistant",
"content": "```python\nfee = 90\nfilings = 3\ntotal = fee * filings # 270\nprint(total)\n```\nPrinted — 270\n\nThe filings cost $270 in all."
}
] | nlprog_det | setting | original | null | deterministic | [] | [] | 82 | {"gold": "270", "printed": "270", "notation": null} |
nlprog_det-setting-0045736 | Rent of $1,500 goes up 8%. What is the new rent?
Python:
```python
rent = 1500
increase = 8 / 100 # 0.08
new_rent = rent * (1 + increase) # 1620.0
print(f"{new_rent:.2f}")
```
That prints 1620.00.
It rises to $1,620.00. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 110 | {"gold": "1620.00", "printed": "1620.00", "notation": null} |
nlprog_det-setting-0045737 | How many 1-foot square tiles cover a 10 ft by 15 ft floor (round up)?
In code:
```python
import math
length = 10
width = 15
tile = 1
tiles = math.ceil(length * width / (tile * tile)) # 150
print(tiles)
```
# run result: 150
It takes 150 tiles. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 104 | {"gold": "150", "printed": "150", "notation": null} |
nlprog_det-setting-0045740 | Fines run at $250 per day up to a maximum of $1,000. How much after 21 days?
Written as code:
```python
per_day = 250
days = 21
cap = 1000
fine = min(per_day * days, cap) # 1000
print(fine)
```
The program prints 1000, as expected.
The fine is $1,000. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 104 | {"gold": "1000", "printed": "1000", "notation": null} |
nlprog_det-setting-0045742 | <|start|><|user|>
A kettle costs $45. It is 30% off. What is the sale price?<|eot|>
<|assistant|>
```python
price = 45
discount = 30 / 100 # 0.3
sale_price = price * (1 - discount) # 31.499999999999996
print(f"{sale_price:.2f}")
```
Run output — 31.50
The sale price is $31.50.<|eot|>
<|end|> | chat | [
{
"role": "user",
"content": "A kettle costs $45. It is 30% off. What is the sale price?"
},
{
"role": "assistant",
"content": "```python\nprice = 45\ndiscount = 30 / 100 # 0.3\nsale_price = price * (1 - discount) # 31.499999999999996\nprint(f\"{sale_price:.2f}\")\n```\nRun output — 31.50\n\nT... | nlprog_det | setting | original | null | deterministic | [] | [] | 117 | {"gold": "31.50", "printed": "31.50", "notation": null} |
nlprog_det-setting-0045743 | Convert 1,630 GBP to USD at 1 GBP = 0.92 USD.
Translated to Python:
```python
amount = 1630
rate = 0.92
converted = amount * rate # 1499.6000000000001
print(f"{converted:.2f}")
```
It prints 1499.60, as expected.
It converts to 1,499.60 USD. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 119 | {"gold": "1499.60", "printed": "1499.60", "notation": null} |
nlprog_det-setting-0045744 | At 2% a month (simple), what interest builds on $2,500 over 2 months?
As Python:
```python
balance = 2500
monthly_rate = 2 / 100 # 0.02
months = 2
interest = balance * monthly_rate * months # 100.0
print(f"{interest:.2f}")
```
# out: 100.00
$100.00 accrues. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 111 | {"gold": "100.00", "printed": "100.00", "notation": null} |
nlprog_det-setting-0045745 | <|start|><|system|>
The following tools are available. Call one when it helps.
[{"name": "search_cases", "description": "Search case law by keyword.", "parameters": {"type": "object", "properties": {"query": {"type": "string"}}, "required": ["query"]}}, {"name": "math_engine", "description": "A Python interpreter. Retu... | chat | [
{
"role": "system",
"content": "The following tools are available. Call one when it helps.\n[{\"name\": \"search_cases\", \"description\": \"Search case law by keyword.\", \"parameters\": {\"type\": \"object\", \"properties\": {\"query\": {\"type\": \"string\"}}, \"required\": [\"query\"]}}, {\"name\": \"ma... | nlprog_det | setting | original | null | deterministic | [] | [] | 304 | {"gold": "28.6", "printed": "28.6", "notation": null} |
nlprog_det-setting-0045746 | Straight-line depreciation: cost $45,000, salvage $3,000, 10 years. How much per year?
We can compute it in Python.
```python
cost = 45000
salvage = 3000
years = 10
per_year = (cost - salvage) / years # 4200.0
print(f"{per_year:.2f}")
```
# printed result: 4200.00
Depreciation is $4,200.00 per year. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 132 | {"gold": "4200.00", "printed": "4200.00", "notation": null} |
nlprog_det-setting-0045747 | <|start|><|system|>
You are a logic tutor.<|eot|>
<|user|>
Monthly: $9. Annual: $96. What is saved per year by paying annually?<|eot|>
<|assistant|>
```python
monthly = 9
yearly = 96
savings = monthly * 12 - yearly # 12
print(savings)
```
This prints 12.
The annual plan saves $12.<|eot|>
<|end|> | chat | [
{
"role": "system",
"content": "You are a logic tutor."
},
{
"role": "user",
"content": "Monthly: $9. Annual: $96. What is saved per year by paying annually?"
},
{
"role": "assistant",
"content": "```python\nmonthly = 9\nyearly = 96\nsavings = monthly * 12 - yearly # 12\nprint(savin... | nlprog_det | setting | original | null | deterministic | [] | [] | 101 | {"gold": "12", "printed": "12", "notation": null} |
nlprog_det-setting-0045748 | A hearing is set for April 19, 2018. What day of the week is that?
The computation:
```python
from datetime import date
hearing = date(2018, 4, 19) # datetime.date(2018, 4, 19)
print(hearing.strftime("%A"))
```
Execution result: Thursday
April 19, 2018 is a Thursday. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 101 | {"gold": "Thursday", "printed": "Thursday", "notation": null} |
nlprog_det-setting-0045749 | What does $2,000 grow to in 5 years at 2% annual compounding?
A few lines of Python do it:
principal = 2000
rate = 2 / 100 # 0.02
years = 5
value = principal * (1 + rate) ** years # 2208.1616064
print(f"{value:.2f}")
Shell output: 2208.16
It is worth $2,208.16. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 109 | {"gold": "2208.16", "printed": "2208.16", "notation": null} |
nlprog_det-setting-0045750 | Counting the first and last day, how many days are there from July 16, 2020 through August 5, 2020?
Python does the arithmetic:
```python
from datetime import date
first = date(2020, 7, 16) # datetime.date(2020, 7, 16)
last = date(2020, 8, 5) # datetime.date(2020, 8, 5)
days = (last - first).days + 1 # 21
print(day... | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 141 | {"gold": "21", "printed": "21", "notation": null} |
nlprog_det-setting-0045751 | <|start|><|user|>
Someone works 40 hours at $21.57 per hour. What are the earnings?<|eot|>
<|assistant|>
```python
rate = 21.57
hours = 40
earnings = rate * hours # 862.8
print(f"{earnings:.2f}")
```
When run, it prints 862.80.
That earns $862.80.<|eot|>
<|end|> | chat | [
{
"role": "user",
"content": "Someone works 40 hours at $21.57 per hour. What are the earnings?"
},
{
"role": "assistant",
"content": "```python\nrate = 21.57\nhours = 40\nearnings = rate * hours # 862.8\nprint(f\"{earnings:.2f}\")\n```\nWhen run, it prints 862.80.\n\nThat earns $862.80."
}
] | nlprog_det | setting | original | null | deterministic | [] | [] | 98 | {"gold": "862.80", "printed": "862.80", "notation": null} |
nlprog_det-setting-0045752 | Viktor was born on October 1, 1974. How old is Viktor on February 12, 2028?
Python:
```python
from datetime import date
born = date(1974, 10, 1) # datetime.date(1974, 10, 1)
on = date(2028, 2, 12) # datetime.date(2028, 2, 12)
age = on.year - born.year - ((on.month, on.day) < (born.month, born.day)) # 53
print(age)
... | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 158 | {"gold": "53", "printed": "53", "notation": null} |
nlprog_det-setting-0045753 | 2 friends split a $96 bill plus a 18% tip evenly. How much does each pay?
Computation in Python:
```python
bill = 96
tip_rate = 18 / 100 # 0.18
people = 2
each = bill * (1 + tip_rate) / people # 56.64
print(f"{each:.2f}")
```
Python prints: 56.64
The share is $56.64 each. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 122 | {"gold": "56.64", "printed": "56.64", "notation": null} |
nlprog_det-setting-0045754 | <|start|><|system|>
Tools (call with JSON):
{"name": "translate", "description": "Translate text into another language.", "parameters": {"type": "object", "properties": {"text": {"type": "string"}, "target": {"type": "string"}}, "required": ["text", "target"]}}
{"name": "calculator", "description": "Executes Python cod... | chat | [
{
"role": "system",
"content": "Tools (call with JSON):\n{\"name\": \"translate\", \"description\": \"Translate text into another language.\", \"parameters\": {\"type\": \"object\", \"properties\": {\"text\": {\"type\": \"string\"}, \"target\": {\"type\": \"string\"}}, \"required\": [\"text\", \"target\"]}}... | nlprog_det | setting | original | null | deterministic | [] | [] | 411 | {"gold": "7.0", "printed": "7.0", "notation": null} |
nlprog_det-setting-0045755 | <|start|><|user|>
Convert 95 km to meters.<|eot|>
<|assistant|>
That is 95,000 meters.<|eot|>
<|end|> | chat | [
{
"role": "user",
"content": "Convert 95 km to meters."
},
{
"role": "assistant",
"content": "That is 95,000 meters."
}
] | nlprog_det | setting | original | null | deterministic | [] | [] | 28 | {"gold": "95000", "printed": "95000", "notation": null} |
nlprog_det-setting-0045757 | <|start|><|system|>
Functions:
[{"name": "define_word", "description": "Return a dictionary definition.", "parameters": {"type": "object", "properties": {"word": {"type": "string"}}, "required": ["word"]}}, {"name": "calculator", "description": "Runs a short Python snippet and returns what it prints.", "parameters": {"... | chat | [
{
"role": "system",
"content": "Functions:\n[{\"name\": \"define_word\", \"description\": \"Return a dictionary definition.\", \"parameters\": {\"type\": \"object\", \"properties\": {\"word\": {\"type\": \"string\"}}, \"required\": [\"word\"]}}, {\"name\": \"calculator\", \"description\": \"Runs a short Pyt... | nlprog_det | setting | original | null | deterministic | [] | [] | 294 | {"gold": "24.80", "printed": "24.80", "notation": null} |
nlprog_det-setting-0045759 | <|start|><|system|>
You are a puzzle helper.<|eot|>
<|user|>
Straight-line depreciation: cost $12,000, salvage $0, 6 years. How much per year?<|eot|>
<|assistant|>
cost = 12000
salvage = 0
years = 6
per_year = (cost - salvage) / years # 2000.0
print(f"{per_year:.2f}")
Run result = 2000.00
Deprecia... | chat | [
{
"role": "system",
"content": "You are a puzzle helper."
},
{
"role": "user",
"content": "Straight-line depreciation: cost $12,000, salvage $0, 6 years. How much per year?"
},
{
"role": "assistant",
"content": " cost = 12000\n salvage = 0\n years = 6\n per_year = (cost -... | nlprog_det | setting | original | null | deterministic | [] | [] | 123 | {"gold": "2000.00", "printed": "2000.00", "notation": null} |
nlprog_det-setting-0045760 | How long, in days, is it from September 5, 2027 until September 8, 2028?
from datetime import date
first = date(2027, 9, 5) # datetime.date(2027, 9, 5)
second = date(2028, 9, 8) # datetime.date(2028, 9, 8)
print((second - first).days)
The program prints: 369
There are 369 days between the two dates. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 113 | {"gold": "369", "printed": "369", "notation": null} |
nlprog_det-setting-0045761 | Water costs $20 a month plus $4.75 for each 1,000 gallons over 3,000. What is owed for 22,000 gallons?
Computation in Python:
```python
base = 20
rate = 4.75
used = 22
free = 3
bill = base + rate * max(0, used - free) # 110.25
print(f"{bill:.2f}")
```
On running, it outputs 110.25.
$110.25 is owed. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 129 | {"gold": "110.25", "printed": "110.25", "notation": null} |
nlprog_det-setting-0045762 | Kofi earns $16.00 an hour and time and a half for hours over 40. What is the pay for a 55-hour week?
Python code:
```python
rate = 16.0
hours = 55
regular = 40 * rate # 640.0
overtime = (hours - 40) * rate * 1.5 # 360.0
pay = regular + overtime # 1000.0
print(f"{pay:.2f}")
```
Program output: 1000.00
Kofi earns $1... | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 143 | {"gold": "1000.00", "printed": "1000.00", "notation": null} |
nlprog_det-setting-0045763 | Starting with 729 desk lamps and using 10 per day, how many remain after 17 days?
```python
stock = 729
per_day = 10
days = 17
left = stock - per_day * days # 559
print(left)
```
# out: 559
559 remain. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 84 | {"gold": "559", "printed": "559", "notation": null} |
nlprog_det-setting-0045764 | A 192-page report must be reviewed in 8 days. How many pages a day is that, evenly?
Translated to Python:
```python
pages = 192
days = 8
per_day = pages // days # 24
print(per_day)
```
Interpreter output: 24
24 pages a day. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 90 | {"gold": "24", "printed": "24", "notation": null} |
nlprog_det-setting-0045765 | How many weekdays (Monday to Friday) fall after May 27, 2028 up to and including June 26, 2028?
Written as code:
```python
from datetime import date, timedelta
start = date(2028, 5, 27)
end = date(2028, 6, 26)
count = 0
for k in range(1, (end - start).days + 1):
if (start + timedelta(days=k)).weekday() < 5:
... | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 158 | {"gold": "21", "printed": "21", "notation": null} |
nlprog_det-setting-0045766 | Monthly rent is $2,400. A tenant moves in with 22 days left in a 30-day month. What is the prorated rent?
Set it up in Python:
```python
rent = 2400
days_in_month = 30
days_occupied = 22
prorated = rent * days_occupied / days_in_month # 1760.0
print(f"{prorated:.2f}")
```
Run result: 1760.00
The prorated rent is $1,... | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 143 | {"gold": "1760.00", "printed": "1760.00", "notation": null} |
nlprog_det-setting-0045767 | <|start|><|user|>
What simple interest does $1,000 earn at 2% a year over 5 years?<|eot|>
<|assistant|>
principal = 1000
rate = 2 / 100 # 0.02
years = 5
interest = principal * rate * years # 100.0
print(f"{interest:.2f}")
That prints: 100.00
It earns $100.00.<|eot|>
<|end|> | chat | [
{
"role": "user",
"content": "What simple interest does $1,000 earn at 2% a year over 5 years?"
},
{
"role": "assistant",
"content": " principal = 1000\n rate = 2 / 100 # 0.02\n years = 5\n interest = principal * rate * years # 100.0\n print(f\"{interest:.2f}\")\nThat prints: 10... | nlprog_det | setting | original | null | deterministic | [] | [] | 93 | {"gold": "100.00", "printed": "100.00", "notation": null} |
nlprog_det-setting-0045768 | <|start|><|system|>
You may call the tools below.
{"name": "compute", "description": "Executes Python code and returns stdout.", "parameters": {"type": "object", "properties": {"program": {"type": "string", "description": "Python source code"}}, "required": ["program"]}}
{"name": "get_weather", "description": "Get the ... | chat | [
{
"role": "system",
"content": "You may call the tools below.\n{\"name\": \"compute\", \"description\": \"Executes Python code and returns stdout.\", \"parameters\": {\"type\": \"object\", \"properties\": {\"program\": {\"type\": \"string\", \"description\": \"Python source code\"}}, \"required\": [\"progra... | nlprog_det | setting | original | null | deterministic | [] | [] | 303 | {"gold": "15000.00", "printed": "15000.00", "notation": null} |
nlprog_det-setting-0045769 | Rosa drove 215 miles for work. Mileage is reimbursed at 70 cents a mile. How much is the reimbursement?
Here's the code.
miles = 215
rate = 0.7
reimbursement = miles * rate # 150.5
print(f"{reimbursement:.2f}")
Running it prints 150.50.
Rosa is owed $150.50. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 102 | {"gold": "150.50", "printed": "150.50", "notation": null} |
nlprog_det-setting-0045770 | After an initial $6,000, the remainder of a $30,000 grant is paid in 3 equal parts. What is each part?
Here is the program.
```python
grant = 30000
up_front = 6000
installments = 3
each = (grant - up_front) / installments # 8000.0
print(f"{each:.2f}")
```
The run gives 8000.00, as expected.
$8,000.00 per installment... | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 123 | {"gold": "8000.00", "printed": "8000.00", "notation": null} |
nlprog_det-setting-0045771 | <|start|><|system|>
Tool definitions:
{"name": "code_runner", "description": "Executes a Python program and returns its output.", "parameters": {"type": "object", "properties": {"source": {"type": "string", "description": "Python source code"}}, "required": ["source"]}}<|eot|>
<|user|>
An office budget of $20,000 has e... | chat | [
{
"role": "system",
"content": "Tool definitions:\n{\"name\": \"code_runner\", \"description\": \"Executes a Python program and returns its output.\", \"parameters\": {\"type\": \"object\", \"properties\": {\"source\": {\"type\": \"string\", \"description\": \"Python source code\"}}, \"required\": [\"source... | nlprog_det | setting | original | null | deterministic | [] | [] | 236 | {"gold": "12489", "printed": "12489", "notation": null} |
nlprog_det-setting-0045772 | A $150 dinner bill gets a 20% tip, and 4 people share the cost equally. What is each person's share?
The share is $45.00 each. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 40 | {"gold": "45.00", "printed": "45.00", "notation": null} |
nlprog_det-setting-0045773 | If a 40-minute seminar begins at 8:20 AM, what time does it finish?
Here is a short program for it.
```python
start = 8 * 60 + 20
end = start + 40
hour, minute = divmod(end, 60)
print(f"{(hour - 1) % 12 + 1}:{minute:02d} {'AM' if hour < 12 else 'PM'}")
```
# result: 9:00 AM
It ends at 9:00 AM. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 130 | {"gold": "9:00 AM", "printed": "9:00 AM", "notation": null} |
nlprog_det-setting-0045774 | Fuel for 450 miles at 20 mpg, with gas at $3.19/gallon: what is the cost? The trip uses $71.78 of gas. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 40 | {"gold": "71.78", "printed": "71.78", "notation": null} |
nlprog_det-setting-0045775 | With 16 rows of 16 chairs and 22 empty chairs, how many chairs are taken?
Here is a short program for it.
```python
rows = 16
per_row = 16
empty = 22
seated = rows * per_row - empty # 234
print(seated)
```
Python prints 234.
234 seats are taken. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 99 | {"gold": "234", "printed": "234", "notation": null} |
nlprog_det-setting-0045776 | Starting from $8,000, the team spends $413, $2,097, $1,049. What remains?
Let the code do the arithmetic:
```python
budget = 8000
expenses = [413, 2097, 1049]
left = budget - sum(expenses) # 4441
print(left)
```
(Printed: 4441)
The remaining budget is $4,441. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 117 | {"gold": "4441", "printed": "4441", "notation": null} |
nlprog_det-setting-0045777 | <|start|><|user|>
2 clients win $96,000. The lawyer takes 30%, and the rest is split equally. How much does each client get?<|eot|>
<|assistant|>
award = 96000
fee = award * 30 / 100 # 28800.0
remaining = award - fee # 67200.0
per_client = remaining / 2 # 33600.0
print(f"{per_client:.2f}")
Consol... | chat | [
{
"role": "user",
"content": "2 clients win $96,000. The lawyer takes 30%, and the rest is split equally. How much does each client get?"
},
{
"role": "assistant",
"content": " award = 96000\n fee = award * 30 / 100 # 28800.0\n remaining = award - fee # 67200.0\n per_client = remai... | nlprog_det | setting | original | null | deterministic | [] | [] | 124 | {"gold": "33600.00", "printed": "33600.00", "notation": null} |
nlprog_det-setting-0045779 | <|start|><|user|>
After a 30% fee is taken from a $30,000 judgment, 2 plaintiffs share the remainder equally. What is each plaintiff's share?<|eot|>
<|assistant|>
```python
award = 30000
fee = award * 30 / 100 # 9000.0
remaining = award - fee # 21000.0
per_client = remaining / 2 # 10500.0
print(f"{per_client:.2f}")
... | chat | [
{
"role": "user",
"content": "After a 30% fee is taken from a $30,000 judgment, 2 plaintiffs share the remainder equally. What is each plaintiff's share?"
},
{
"role": "assistant",
"content": "```python\naward = 30000\nfee = award * 30 / 100 # 9000.0\nremaining = award - fee # 21000.0\nper_cli... | nlprog_det | setting | original | null | deterministic | [] | [] | 143 | {"gold": "10500.00", "printed": "10500.00", "notation": null} |
nlprog_det-setting-0045780 | Under a 30% contingency agreement, what fee is owed on a $150,000 award?
The fee is $45,000.00. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 33 | {"gold": "45000.00", "printed": "45000.00", "notation": null} |
nlprog_det-setting-0045781 | <|start|><|user|>
Each of Amir's swims burns 350 calories. How many calories over 5 swims?<|eot|>
<|assistant|>
```python
per_session = 350
sessions = 5
total = per_session * sessions # 1750
print(total)
```
It prints 1750, as expected.
That burns 1750 calories.<|eot|>
<|end|> | chat | [
{
"role": "user",
"content": "Each of Amir's swims burns 350 calories. How many calories over 5 swims?"
},
{
"role": "assistant",
"content": "```python\nper_session = 350\nsessions = 5\ntotal = per_session * sessions # 1750\nprint(total)\n```\nIt prints 1750, as expected.\n\nThat burns 1750 cal... | nlprog_det | setting | original | null | deterministic | [] | [] | 96 | {"gold": "1750", "printed": "1750", "notation": null} |
nlprog_det-setting-0045782 | <|start|><|user|>
What day of the week is December 19, 2007?<|eot|>
<|assistant|>
```python
from datetime import date
hearing = date(2007, 12, 19) # datetime.date(2007, 12, 19)
print(hearing.strftime("%A"))
```
Run output — Wednesday
December 19, 2007 is a Wednesday.<|eot|>
<|end|> | chat | [
{
"role": "user",
"content": "What day of the week is December 19, 2007?"
},
{
"role": "assistant",
"content": "```python\nfrom datetime import date\nhearing = date(2007, 12, 19) # datetime.date(2007, 12, 19)\nprint(hearing.strftime(\"%A\"))\n```\nRun output — Wednesday\n\nDecember 19, 2007 is ... | nlprog_det | setting | original | null | deterministic | [] | [] | 97 | {"gold": "Wednesday", "printed": "Wednesday", "notation": null} |
nlprog_det-setting-0045783 | Monthly rent is $1,200. A tenant moves in with 22 days left in a 30-day month. What is the prorated rent?
The Python version:
```python
rent = 1200
days_in_month = 30
days_occupied = 22
prorated = rent * days_occupied / days_in_month # 880.0
print(f"{prorated:.2f}")
```
The script prints: 880.00
The prorated rent is... | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 139 | {"gold": "880.00", "printed": "880.00", "notation": null} |
nlprog_det-setting-0045784 | A 4% increase is applied to $1,250 monthly rent. What is the new amount?
Python:
```python
rent = 1250
increase = 4 / 100 # 0.04
new_rent = rent * (1 + increase) # 1300.0
print(f"{new_rent:.2f}")
```
It prints 1300.00.
The new rent is $1,300.00. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 109 | {"gold": "1300.00", "printed": "1300.00", "notation": null} |
nlprog_det-setting-0045785 | An office budget of $25,000 has expenses of $1,599, $1,657. How much of the budget is left?
As a program:
```python
budget = 25000
expenses = [1599, 1657]
left = budget - sum(expenses) # 21744
print(left)
```
Execution result: 21744
$21,744 is left. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 108 | {"gold": "21744", "printed": "21744", "notation": null} |
nlprog_det-setting-0045786 | Monthly rent is $2,400. A tenant moves in with 17 days left in a 31-day month. What is the prorated rent?
Coded up:
```python
rent = 2400
days_in_month = 31
days_occupied = 17
prorated = rent * days_occupied / days_in_month # 1316.1290322580646
print(f"{prorated:.2f}")
```
Run output — 1316.13
The prorated rent is $... | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 144 | {"gold": "1316.13", "printed": "1316.13", "notation": null} |
nlprog_det-setting-0045787 | A quorum is 3/5 of the 37 members, rounded up. How many members make a quorum?
```python
import math
members = 37
quorum = math.ceil(members * 3 / 5) # 23
print(quorum)
```
Program output — 23
That is 23 members. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 88 | {"gold": "23", "printed": "23", "notation": null} |
nlprog_det-setting-0045788 | <|start|><|user|>
At 30 miles per hour, how many minutes does a 130-mile trip take?<|eot|>
<|assistant|>
distance = 130
speed = 30
minutes = distance / speed * 60 # 260.0
print(round(minutes))
When run, it prints: 260
The trip takes 260 minutes.<|eot|>
<|end|> | chat | [
{
"role": "user",
"content": "At 30 miles per hour, how many minutes does a 130-mile trip take?"
},
{
"role": "assistant",
"content": " distance = 130\n speed = 30\n minutes = distance / speed * 60 # 260.0\n print(round(minutes))\nWhen run, it prints: 260\n\nThe trip takes 260 minut... | nlprog_det | setting | original | null | deterministic | [] | [] | 76 | {"gold": "260", "printed": "260", "notation": null} |
nlprog_det-setting-0045789 | <|start|><|system|>
Functions:
[{"name": "math_engine", "description": "Python sandbox for calculations. Returns printed text.", "parameters": {"type": "object", "properties": {"program": {"type": "string", "description": "Python source code"}}, "required": ["program"]}}]<|eot|>
<|user|>
How much sales tax is charged o... | chat | [
{
"role": "system",
"content": "Functions:\n[{\"name\": \"math_engine\", \"description\": \"Python sandbox for calculations. Returns printed text.\", \"parameters\": {\"type\": \"object\", \"properties\": {\"program\": {\"type\": \"string\", \"description\": \"Python source code\"}}, \"required\": [\"progra... | nlprog_det | setting | original | null | deterministic | [] | [] | 211 | {"gold": "36.00", "printed": "36.00", "notation": null} |
nlprog_det-setting-0045790 | Copies cost $15 plus $0.25 for each page beyond 20. How much for 11 pages?
```python
pages = 11
base = 15
per_page = 0.25
free_pages = 20
cost = base + max(0, pages - free_pages) * per_page # 15.0
print(f"{cost:.2f}")
```
Interpreter output — 15.00
The total is $15.00. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 119 | {"gold": "15.00", "printed": "15.00", "notation": null} |
nlprog_det-setting-0045792 | A hall has 29 rows of 15 seats, and 21 seats are empty. How many people are seated?
Script:
```python
rows = 29
per_row = 15
empty = 21
seated = rows * per_row - empty # 414
print(seated)
```
(Out: 414)
414 people are seated. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 96 | {"gold": "414", "printed": "414", "notation": null} |
nlprog_det-setting-0045793 | What does $10,000 grow to in 2 years at 4% annual compounding?
In Python:
principal = 10000
rate = 4 / 100 # 0.04
years = 2
value = principal * (1 + rate) ** years # 10816.000000000002
print(f"{value:.2f}")
This prints 10816.00, as expected.
It is worth $10,816.00. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 113 | {"gold": "10816.00", "printed": "10816.00", "notation": null} |
nlprog_det-setting-0045794 | Shipping costs $10 plus $1.50 per pound. What does a 14-pound parcel cost to ship?
Program:
```python
base = 10
per_pound = 1.5
weight = 14
cost = base + per_pound * weight # 31.0
print(f"{cost:.2f}")
```
The code prints: 31.00
The charge is $31.00. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 108 | {"gold": "31.00", "printed": "31.00", "notation": null} |
nlprog_det-setting-0045795 | A claim accrued on May 21, 2021. The limitations period is 3 years. On what date does it expire?
Written as code:
```python
from datetime import date
accrued = date(2021, 5, 21) # datetime.date(2021, 5, 21)
years = 3
expires = accrued.replace(year=accrued.year + years) # datetime.date(2024, 5, 21)
print(expires.isof... | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 149 | {"gold": "2024-05-21", "printed": "2024-05-21", "notation": null} |
nlprog_det-setting-0045796 | <|start|><|user|>
The firm was founded in 2006. How many years had passed by 2046?<|eot|>
<|assistant|>
```python
start_year = 2006
end_year = 2046
print(end_year - start_year)
```
On running, it outputs 40.
That is 40 years.<|eot|>
<|end|> | chat | [
{
"role": "user",
"content": "The firm was founded in 2006. How many years had passed by 2046?"
},
{
"role": "assistant",
"content": "```python\nstart_year = 2006\nend_year = 2046\nprint(end_year - start_year)\n```\nOn running, it outputs 40.\n\nThat is 40 years."
}
] | nlprog_det | setting | original | null | deterministic | [] | [] | 76 | {"gold": "40", "printed": "40", "notation": null} |
nlprog_det-setting-0045797 | Noor earns $18.50 an hour and time and a half for hours over 40. What is the pay for a 49-hour week?
```python
rate = 18.5
hours = 49
regular = 40 * rate # 740.0
overtime = (hours - 40) * rate * 1.5 # 249.75
pay = regular + overtime # 989.75
print(f"{pay:.2f}")
```
Executed, it shows: 989.75
Noor earns $989.75. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 136 | {"gold": "989.75", "printed": "989.75", "notation": null} |
nlprog_det-setting-0045798 | <|start|><|user|>
Cyrus earns $16.00 an hour and time and a half for hours over 40. What is the pay for a 55-hour week?<|eot|>
<|assistant|>
```python
rate = 16.0
hours = 55
regular = 40 * rate # 640.0
overtime = (hours - 40) * rate * 1.5 # 360.0
pay = regular + overtime # 1000.0
print(f"{pay:.2f}")
```
# stdout: 10... | chat | [
{
"role": "user",
"content": "Cyrus earns $16.00 an hour and time and a half for hours over 40. What is the pay for a 55-hour week?"
},
{
"role": "assistant",
"content": "```python\nrate = 16.0\nhours = 55\nregular = 40 * rate # 640.0\novertime = (hours - 40) * rate * 1.5 # 360.0\npay = regula... | nlprog_det | setting | original | null | deterministic | [] | [] | 143 | {"gold": "1000.00", "printed": "1000.00", "notation": null} |
nlprog_det-setting-0045799 | A storeroom has 1940 folders. The office uses 38 a day. How many are left after 20 days?
We write it as a program:
```python
stock = 1940
per_day = 38
days = 20
left = stock - per_day * days # 1180
print(left)
```
The interpreter prints: 1180
1180 remain. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 96 | {"gold": "1180", "printed": "1180", "notation": null} |
nlprog_det-setting-0045800 | <|start|><|system|>
Available functions (JSON Schema):
[{"name": "interpreter", "description": "Runs a short Python snippet and returns what it prints.", "parameters": {"type": "object", "properties": {"source": {"type": "string", "description": "Python source code"}}, "required": ["source"]}}]<|eot|>
<|user|>
An invoi... | chat | [
{
"role": "system",
"content": "Available functions (JSON Schema):\n[{\"name\": \"interpreter\", \"description\": \"Runs a short Python snippet and returns what it prints.\", \"parameters\": {\"type\": \"object\", \"properties\": {\"source\": {\"type\": \"string\", \"description\": \"Python source code\"}},... | nlprog_det | setting | original | null | deterministic | [] | [] | 252 | {"gold": "372.06", "printed": "372.06", "notation": null} |
nlprog_det-setting-0045801 | Buying 3 tape rolls at $22 each, 5 chairs at $13 each, someone hands over $150. What change comes back?
Programmatically:
```python
items = [(3, 22), (5, 13)]
total = sum(q * p for q, p in items) # 131
paid = 150
change = paid - total # 19
print(change)
```
Program output: 19
The change is $19. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 119 | {"gold": "19", "printed": "19", "notation": null} |
nlprog_det-setting-0045802 | What is the total rent on a 36-month lease at $1,475 a month?
A short script:
```python
monthly_rent = 1475
months = 36
total = monthly_rent * months # 53100
print(total)
```
Shell output — 53100
In total, $53,100 is paid. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 90 | {"gold": "53100", "printed": "53100", "notation": null} |
nlprog_det-setting-0045803 | What is a 25% tip on a $239.37 bill?
The program:
```python
bill = 239.37
tip_rate = 25 / 100 # 0.25
tip = bill * tip_rate # 59.8425
print(f"{tip:.2f}")
```
Running it prints: 59.84
The tip is $59.84. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 103 | {"gold": "59.84", "printed": "59.84", "notation": null} |
nlprog_det-setting-0045804 | How many weekdays (Monday to Friday) fall after November 24, 2028 up to and including December 21, 2028?
The computation:
```python
from datetime import date, timedelta
start = date(2028, 11, 24)
end = date(2028, 12, 21)
count = 0
for k in range(1, (end - start).days + 1):
if (start + timedelta(days=k)).weekday() ... | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 156 | {"gold": "19", "printed": "19", "notation": null} |
nlprog_det-setting-0045805 | <|start|><|user|>
A pack of 5 sticky pads sells for $205. What does each cost?<|eot|>
<|assistant|>
```python
total = 205
count = 5
per_item = total // count
print(per_item)
```
The run gives: 41
Each one costs $41.<|eot|>
<|end|> | chat | [
{
"role": "user",
"content": "A pack of 5 sticky pads sells for $205. What does each cost?"
},
{
"role": "assistant",
"content": "```python\ntotal = 205\ncount = 5\nper_item = total // count\nprint(per_item)\n```\nThe run gives: 41\n\nEach one costs $41."
}
] | nlprog_det | setting | original | null | deterministic | [] | [] | 81 | {"gold": "41", "printed": "41", "notation": null} |
nlprog_det-setting-0045806 | 234 files go into boxes of 12. How many boxes does that take?
As Python:
```python
import math
files = 234
per_box = 12
boxes = math.ceil(files / per_box) # 20
print(boxes)
```
This prints 20, as expected.
20 boxes are needed. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 96 | {"gold": "20", "printed": "20", "notation": null} |
nlprog_det-setting-0045807 | How many minutes pass from 10:11 AM to 10:42 AM on the same day?
Here is a short program for it.
```python
start = 10 * 60 + 11 # 611
end = 10 * 60 + 42 # 642
print(end - start)
```
Execution prints 31, as expected.
31 minutes pass. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 87 | {"gold": "31", "printed": "31", "notation": null} |
nlprog_det-setting-0045809 | How many minutes pass from 10:10 AM to 4:41 PM on the same day?
Code:
```python
start = 10 * 60 + 10 # 610
end = 16 * 60 + 41 # 1001
print(end - start)
```
Output of the run: 391
391 minutes pass. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 82 | {"gold": "391", "printed": "391", "notation": null} |
nlprog_det-setting-0045810 | A 15 × 11 foot patio is tiled with 1 ft × 1 ft tiles. How many tiles, rounded up?
Written as code:
```python
import math
length = 15
width = 11
tile = 1
tiles = math.ceil(length * width / (tile * tile)) # 165
print(tiles)
```
(Console output: 165)
165 tiles are needed. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 121 | {"gold": "165", "printed": "165", "notation": null} |
nlprog_det-setting-0045811 | What percentage of $2,000 is $1,800?
Let's compute it with Python.
budget = 2000
spent = 1800
percent = spent / budget * 100 # 90.0
print(round(percent, 1))
# result: 90.0
That is 90.0% of the budget. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 78 | {"gold": "90.0", "printed": "90.0", "notation": null} |
nlprog_det-setting-0045813 | A lawyer's fee is 35% of a $60,000 recovery. How large is the fee? The fee is $21,000.00. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 32 | {"gold": "21000.00", "printed": "21000.00", "notation": null} |
nlprog_det-setting-0045814 | A printer costs $75. It is 10% off. What is the sale price?
Programmatically:
```python
price = 75
discount = 10 / 100 # 0.1
sale_price = price * (1 - discount) # 67.5
print(f"{sale_price:.2f}")
```
Executed, it shows 67.50.
It costs $67.50. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 109 | {"gold": "67.50", "printed": "67.50", "notation": null} |
nlprog_det-setting-0045815 | <|start|><|user|>
A pack of 8 binders sells for $232. What does each cost?<|eot|>
<|assistant|>
```python
total = 232
count = 8
per_item = total // count # 29
print(per_item)
```
Running it prints: 29
Each one costs $29.<|eot|>
<|end|> | chat | [
{
"role": "user",
"content": "A pack of 8 binders sells for $232. What does each cost?"
},
{
"role": "assistant",
"content": "```python\ntotal = 232\ncount = 8\nper_item = total // count # 29\nprint(per_item)\n```\nRunning it prints: 29\n\nEach one costs $29."
}
] | nlprog_det | setting | original | null | deterministic | [] | [] | 85 | {"gold": "29", "printed": "29", "notation": null} |
nlprog_det-setting-0045816 | Convert 1 h 43 min (the length of a film) to minutes.
A short script:
```python
hours = 1
minutes = 43
total_minutes = hours * 60 + minutes # 103
print(total_minutes)
```
The run gives: 103
That is 103 minutes. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 81 | {"gold": "103", "printed": "103", "notation": null} |
nlprog_det-setting-0045817 | <|start|><|system|>
Be exact with numbers.<|eot|>
<|user|>
Goods bought on November 18, 2022 carry a 36-month warranty. When does it expire?<|eot|>
<|assistant|>
```python
from datetime import date
start = date(2022, 11, 18)
months = 36
years, month_index = divmod(start.month - 1 + months, 12)
end = date(start.year + y... | chat | [
{
"role": "system",
"content": "Be exact with numbers."
},
{
"role": "user",
"content": "Goods bought on November 18, 2022 carry a 36-month warranty. When does it expire?"
},
{
"role": "assistant",
"content": "```python\nfrom datetime import date\nstart = date(2022, 11, 18)\nmonths =... | nlprog_det | setting | original | null | deterministic | [] | [] | 156 | {"gold": "2025-11-18", "printed": "2025-11-18", "notation": null} |
nlprog_det-setting-0045818 | Find the mean of these test scores: 75, 51 and 93.
A Python solution:
```python
scores = [75, 51, 93]
average = sum(scores) // len(scores) # 73
print(average)
```
Running this gives 73.
The mean is 73. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 87 | {"gold": "73", "printed": "73", "notation": null} |
nlprog_det-setting-0045819 | What is the total rent on a 18-month lease at $3,250 a month?
A short script:
```python
monthly_rent = 3250
months = 18
total = monthly_rent * months # 58500
print(total)
```
(Output: 58500)
The rent over the term is $58,500. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 91 | {"gold": "58500", "printed": "58500", "notation": null} |
nlprog_det-setting-0045820 | Fixed costs are $1,200. Each unit sells for $15 and costs $5 to make. How many units must be sold to break even?
Python code:
```python
import math
fixed = 1200
price = 15
variable = 5
units = math.ceil(fixed / (price - variable)) # 120
print(units)
```
# stdout: 120
120 units are needed. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 113 | {"gold": "120", "printed": "120", "notation": null} |
nlprog_det-setting-0045823 | <|start|><|user|>
A quorum is 2/3 of the 57 members, rounded up. How many members make a quorum?<|eot|>
<|assistant|>
```python
import math
members = 57
quorum = math.ceil(members * 2 / 3) # 38
print(quorum)
```
The script prints 38.
38 members are needed.<|eot|>
<|end|> | chat | [
{
"role": "user",
"content": "A quorum is 2/3 of the 57 members, rounded up. How many members make a quorum?"
},
{
"role": "assistant",
"content": "```python\nimport math\nmembers = 57\nquorum = math.ceil(members * 2 / 3) # 38\nprint(quorum)\n```\nThe script prints 38.\n\n38 members are needed.... | nlprog_det | setting | original | null | deterministic | [] | [] | 94 | {"gold": "38", "printed": "38", "notation": null} |
nlprog_det-setting-0045824 | <|start|><|system|>
Tool definitions:
[{"name": "py_exec", "description": "Evaluates Python and returns the printed output.", "parameters": {"type": "object", "properties": {"source": {"type": "string", "description": "Python source code"}}, "required": ["source"]}}]<|eot|>
<|user|>
Straight-line depreciation: cost $18... | chat | [
{
"role": "system",
"content": "Tool definitions:\n[{\"name\": \"py_exec\", \"description\": \"Evaluates Python and returns the printed output.\", \"parameters\": {\"type\": \"object\", \"properties\": {\"source\": {\"type\": \"string\", \"description\": \"Python source code\"}}, \"required\": [\"source\"]}... | nlprog_det | setting | original | null | deterministic | [] | [] | 237 | {"gold": "2000.00", "printed": "2000.00", "notation": null} |
nlprog_det-setting-0045825 | A meal costs $124.02. How much is a 22% tip?
Let's compute it with Python.
```python
bill = 124.02
tip_rate = 22 / 100 # 0.22
tip = bill * tip_rate # 27.284399999999998
print(f"{tip:.2f}")
```
Run it and it prints 27.28.
Leave $27.28. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 118 | {"gold": "27.28", "printed": "27.28", "notation": null} |
nlprog_det-setting-0045826 | What simple interest does $8,000 earn at 4% a year over 2 years?
Coded up:
```python
principal = 8000
rate = 4 / 100 # 0.04
years = 2
interest = principal * rate * years # 640.0
print(f"{interest:.2f}")
```
# console output: 640.00
It earns $640.00. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 109 | {"gold": "640.00", "printed": "640.00", "notation": null} |
nlprog_det-setting-0045827 | <|start|><|system|>
Answer in plain English.<|eot|>
<|user|>
A penalty of $50 a day accrues, capped at $1,000. What is owed after 31 days?<|eot|>
<|assistant|>
```python
per_day = 50
days = 31
cap = 1000
fine = min(per_day * days, cap) # 1000
print(fine)
```
On running, it outputs 1000.
The fine is $1,000.<|eot|>
<|e... | chat | [
{
"role": "system",
"content": "Answer in plain English."
},
{
"role": "user",
"content": "A penalty of $50 a day accrues, capped at $1,000. What is owed after 31 days?"
},
{
"role": "assistant",
"content": "```python\nper_day = 50\ndays = 31\ncap = 1000\nfine = min(per_day * days, c... | nlprog_det | setting | original | null | deterministic | [] | [] | 114 | {"gold": "1000", "printed": "1000", "notation": null} |
nlprog_det-setting-0045828 | A 3-day trip pays $79 a day for meals and $110 a night for lodging (2 nights). What is the total allowance?
Computing it:
days = 3
meal_rate = 79
lodging_rate = 110
nights = days - 1 # 2
total = days * meal_rate + nights * lodging_rate # 457
print(total)
Printed — 457
The allowance is $457. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 112 | {"gold": "457", "printed": "457", "notation": null} |
nlprog_det-setting-0045829 | If a 5-year limitations period starts on September 13, 2014, when does it end?
Let's compute it with Python.
```python
from datetime import date
accrued = date(2014, 9, 13) # datetime.date(2014, 9, 13)
years = 5
expires = accrued.replace(year=accrued.year + years) # datetime.date(2019, 9, 13)
print(expires.isoformat... | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 149 | {"gold": "2019-09-13", "printed": "2019-09-13", "notation": null} |
nlprog_det-setting-0045830 | Buying 2 desk lamps at $4 each, 6 calendars at $13 each, 4 rulers at $21 each, 3 pens at $28 each, someone hands over $300. What change comes back?
Translated to Python:
```python
items = [(2, 4), (6, 13), (4, 21), (3, 28)]
total = sum(q * p for q, p in items) # 254
paid = 300
change = paid - total # 46
print(change... | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 149 | {"gold": "46", "printed": "46", "notation": null} |
nlprog_det-setting-0045831 | <|start|><|system|>
Use a tool when a calculation is needed. Tools:
[{"name": "run_python", "description": "Use for arithmetic and date math; returns stdout of the code.", "parameters": {"type": "object", "properties": {"code": {"type": "string", "description": "Python source code"}}, "required": ["code"]}}]<|eot|>
<|u... | chat | [
{
"role": "system",
"content": "Use a tool when a calculation is needed. Tools:\n[{\"name\": \"run_python\", \"description\": \"Use for arithmetic and date math; returns stdout of the code.\", \"parameters\": {\"type\": \"object\", \"properties\": {\"code\": {\"type\": \"string\", \"description\": \"Python ... | nlprog_det | setting | original | null | deterministic | [] | [] | 293 | {"gold": "17", "printed": "17", "notation": null} |
nlprog_det-setting-0045832 | <|start|><|user|>
Which is cheaper per unit: 6 for $8.30 (A) or 30 for $21.31 (B)?<|eot|>
<|assistant|>
Pack B is cheaper per item.<|eot|>
<|end|> | chat | [
{
"role": "user",
"content": "Which is cheaper per unit: 6 for $8.30 (A) or 30 for $21.31 (B)?"
},
{
"role": "assistant",
"content": "Pack B is cheaper per item."
}
] | nlprog_det | setting | original | null | deterministic | [] | [] | 45 | {"gold": "B", "printed": "B", "notation": null} |
nlprog_det-setting-0045833 | Copies cost $5 plus $0.10 for each page beyond 20. How much for 75 pages?
We write it as a program:
pages = 75
base = 5
per_page = 0.1
free_pages = 20
cost = base + max(0, pages - free_pages) * per_page # 10.5
print(f"{cost:.2f}")
The program outputs 10.50.
The total is $10.50. | plain | null | nlprog_det | setting | original | null | deterministic | [] | [] | 112 | {"gold": "10.50", "printed": "10.50", "notation": null} |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.