Standard Error of the Mean
Voltway Cells tests batteries in batches. A test runs some number of cells to exhaustion and measures how long each lasted, and the lab reports two figures for the batch: how many cells were tested, and the sample standard deviation of their lifetimes in hours - that is, how far an individual cell typically sat from the batch's own average.
Before quoting a batch average to a customer, the engineer wants to know how solid that average is. If the lab ran the identical test again on the same number of fresh cells, the new average would not come out the same; the question is by how much it would typically differ. Batches vary in size, so the line has to work for whatever the lab sends over.
Task: Print the standard error of the mean for the batch, in hours, using the sample standard deviation given. Print the raw number - no rounding is asked for.
Input
The first line holds one integer, the number of cells tested (at least 1). The second line holds the sample standard deviation of their lifetimes in hours, a decimal number.
Output
One line holding the standard error in hours, printed the way Python prints a float.
Example:
Input:
25
10
Output:
2.0
Sign in to solve this problem
Reading problems is free for everyone — solving them (Run, Submit, and tracking what you've solved) needs an account.
Sign in