Cody

Solution 1667210

Submitted on 6 Nov 2018 by James
  • Size: 21
  • 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
v_in = 100; % km/h yearsCorrect = 241830; % years years = becomeOneSecondYounger(v_in); assert(abs(yearsCorrect-years)<10)

years = 241830

2   Pass
v_in = 1000; % km/h yearsCorrect = 2418.7; % years years = becomeOneSecondYounger(v_in); assert(abs(yearsCorrect-years)<0.1)

years = 2.4187e+03

3   Pass
v_in = 10000; % km/h yearsCorrect = 24.187; % years years = becomeOneSecondYounger(v_in); assert(abs(yearsCorrect-years)<0.01)

years = 24.1870