Cody

Problem 2402. Area of a Square

Solution 3807978

Submitted on 24 Nov 2020
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   Fail
r = 2; y_correct = 16; assert(isequal(area_sqr(r),y_correct))

A = 4

Assertion failed.

2   Fail
r = 3; y_correct = 36; assert(isequal(area_sqr(r),y_correct))

A = 9

Assertion failed.

3   Fail
r = 25; y_correct = 2500; assert(isequal(area_sqr(r),y_correct))

A = 625

Assertion failed.

Suggested Problems

More from this Author3

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!