Cody

Problem 45538. Find the area of ​​the square

Solution 2689226

Submitted on 13 Jul 2020 by EmilyR
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
a = 8; n = 5; y = 1600; assert(isequal(squartArea(n,a),y))

2   Pass
a = 0; n = 10; y = 0; assert(isequal(squartArea(n,a),y))

3   Pass
a = 100/pi; n = 6; y = 36476; tolerance = 1e-12; assert(abs(36476-y)<tolerance)

4   Pass
a = 15; n = 0; y = 0; assert(isequal(squartArea(n,a),y))

5   Pass
a = 10; n = 2; y = 400; assert(isequal(squartArea(n,a),y))

Suggested Problems

More from this Author2