Cody

# Problem 3005. Recursive Standard Deviation

Solution 1813331

Submitted on 12 May 2019
This solution is locked. To view this solution, you need to provide a solution of the same size or smaller.

### Test Suite

Test Status Code Input and Output
1   Fail
std_p=0.5 mean_p=0.5 mean_n=2/3 value=1 y_correct=0.4714 assert(abs(recursive_std(std_p,mean_p,mean_n,value)-y_correct)<1e-4)

std_p = 0.5000 mean_p = 0.5000 mean_n = 0.6667 value = 1 y_correct = 0.4714

Output argument "y_correct" (and maybe others) not assigned during call to "recursive_std". Error in Test1 (line 7) assert(abs(recursive_std(std_p,mean_p,mean_n,value)-y_correct)<1e-4)

2   Fail
std_p=.5 mean_p=1.5 mean_n=2 value=3 y_correct=0.8165 assert(abs(recursive_std(std_p,mean_p,mean_n,value)-y_correct)<1e-4)

std_p = 0.5000 mean_p = 1.5000 mean_n = 2 value = 3 y_correct = 0.8165

Output argument "y_correct" (and maybe others) not assigned during call to "recursive_std". Error in Test2 (line 7) assert(abs(recursive_std(std_p,mean_p,mean_n,value)-y_correct)<1e-4)

3   Fail
std_p=5 mean_p=4 mean_n=7.6667 value=15 y_correct=6.5997 assert(abs(recursive_std(std_p,mean_p,mean_n,value)-y_correct)<1e-4)

std_p = 5 mean_p = 4 mean_n = 7.6667 value = 15 y_correct = 6.5997

Output argument "y_correct" (and maybe others) not assigned during call to "recursive_std". Error in Test3 (line 7) assert(abs(recursive_std(std_p,mean_p,mean_n,value)-y_correct)<1e-4)