Cody

Solution 1721380

Submitted on 5 Feb 2019 by Alfonso Nieto-Castanon
  • Size: 38
  • This is the leading solution.
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   Pass
mu = 10; safeLimits = [4 15]; assert(isequal(getLimits(mu), safeLimits))

2   Pass
mu = 100; safeLimits = [83 117]; assert(isequal(getLimits(mu), safeLimits))

3   Pass
mu = 3; safeLimits = [0 6]; assert(isequal(getLimits(mu), safeLimits))

4   Pass
mu = 30; safeLimits = [20 39]; assert(isequal(getLimits(mu), safeLimits))

5   Pass
mu = 4; safeLimits = [0 8]; assert(isequal(getLimits(mu), safeLimits))

6   Pass
mu = 40; safeLimits = [29 51]; assert(isequal(getLimits(mu), safeLimits))

7   Pass
mu = 11; safeLimits = [5 17]; assert(isequal(getLimits(mu), safeLimits))

8   Pass
mu = 12; safeLimits = [6 18]; assert(isequal(getLimits(mu), safeLimits))

9   Pass
mu = 13; safeLimits = [6 19]; assert(isequal(getLimits(mu), safeLimits))

10   Pass
mu = 14; safeLimits = [7 20]; assert(isequal(getLimits(mu), safeLimits))

11   Pass
mu = 15; safeLimits = [8 22]; assert(isequal(getLimits(mu), safeLimits))

12   Pass
mu = 20; safeLimits = [12 28]; assert(isequal(getLimits(mu), safeLimits))

13   Pass
mu = 110; safeLimits = [92 128]; assert(isequal(getLimits(mu), safeLimits))

14   Pass
mu = 120; safeLimits = [101 138]; assert(isequal(getLimits(mu), safeLimits))

15   Pass
% Not asserted in this problem mu = 150; safeLimits = [129 170]; %assert(isequal(getLimits(mu), safeLimits)) mu = 200; safeLimits = [176 224]; %assert(isequal(getLimits(mu), safeLimits)) mu = 300; safeLimits = [271 329]; %assert(isequal(getLimits(mu), safeLimits)) mu = 1000; safeLimits = [947 1052]; %assert(isequal(getLimits(mu), safeLimits))