<｜begin▁of▁sentence｜>### Instruction:
Given a dataset, can you use the percentile function to calculate the 40th percentile and then calculate multiple percentiles at 0th, 25th, 50th, 75th, and 100th?
### Response:
from scipy import stats

# Define the data
values = [15, 20, 40, 35, 50]

# Calculate the 40th percentile
percentile_40 = stats.scoreatpercentile(values, 40)
print(f'40th Percentile: {percentile_40}')

# Calculate multiple percentiles: 0th, 25th, 50th, 75th, 100th
percentiles = [0, 25, 50, 75, 100]
results = [stats.scoreatpercentile(values, p) for p in percentiles]
for p, score in zip(percentiles, results):
    print(f'{p}th Percentile: {score}')
<|EOT|>
