Cody

Solution 264331

Submitted on 20 Jun 2013 by Dan
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
%% diameter = 12; cost = 12; value_correct = 0.1061; assert ( abs(PizzaValue(diameter, cost) - value_correct) < 0.0001)
ans = 0.1061
2   Pass
%% diameter = 16; cost = 18; value_correct = 0.0895; assert ( abs(PizzaValue(diameter, cost) - value_correct) < 0.0001)
ans = 0.0895
3   Pass
%% diameter = 20; cost = 24; value_correct = 0.0764; assert ( abs(PizzaValue(diameter, cost) - value_correct) < 0.0001)
ans = 0.0764