Cody

Problem 44273. Given a square and a circle, please decide whether the square covers more area.

Solution 1244985

Submitted on 3 Aug 2017
This solution is locked. To view this solution, you need to provide a solution of the same size or smaller.

This solution is outdated. To rescore this solution, sign in.

Test Suite

Test Status Code Input and Output
1   Pass
sq = 2; ci = 1; y_correct = (sq>ci); assert(isequal(sqci(sq,ci),y_correct))

2   Fail
sq = rand; ci = rand; y_correct = (4*sq^2>pi*ci^2); assert(isequal(sqci(sq,ci),y_correct))

Assertion failed.

3   Fail
sq = 0; ci = 0; y_correct = (0>0); assert(isequal(sqci(sq,ci),y_correct))

Assertion failed.

Suggested Problems

More from this Author100