Cody

Solution 1935658

Submitted on 14 Sep 2019
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
x = [1 1; 1 -1; -1 1; -1 -1; 0 0]; y_correct = 4; assert(isequal(cover_area(x),y_correct))

s = Area with properties: FaceColor: [0 0.4470 0.7410] EdgeColor: [0 0 0] LineStyle: '-' LineWidth: 0.5000 BaseValue: 0 XData: [1 1 -1 -1 0] YData: [1 -1 1 -1 0] Show all properties

Assertion failed.

Afayyd+uxsy9aaaaaelftksuqmcc"}]
2   Fail
x = [1 1; 1 -2; -2 1; -1 -2; 2 -1; -3 0; 0.2*randn(4,2)]; y_correct = 11; assert(isequal(cover_area(x),y_correct))

s = Area with properties: FaceColor: [0 0.4470 0.7410] EdgeColor: [0 0 0] LineStyle: '-' LineWidth: 0.5000 BaseValue: 0 XData: [1 1 -2 -1 2 -3 -0.1685 0.4618 0.1476 -0.3171] YData: [1 -2 1 -2 -1 0 -0.1068 0.1205 -0.2961 -0.3565] Show all properties

Assertion failed.

Aav3ilwql+seaaaaaelftksuqmcc"}]
3   Fail
x = [1 1; 1 -2; -1 1; -1 -2; 3 4; 0.2*randn(10,2)]; y_correct = 12; assert(isequal(cover_area(x),y_correct))

s = Area with properties: FaceColor: [0 0.4470 0.7410] EdgeColor: [0 0 0] LineStyle: '-' LineWidth: 0.5000 BaseValue: 0 XData: [1 1 -1 -1 3 -0.2506 0.0982 0.2473 0.4495 -0.3800 0.2788 -0.2922 -0.2212 0.1431 0.0081] YData: [1 -2 1 -2 4 -0.0139 0.0128 -0.0941 -0.1524 -0.0384 -0.0429 0.2791 0.0620 -0.0141 0.0659] Show all properties

Assertion failed.

N5cx3azoefkc3kf2ch++uuvnz2d7ova4heoagckq9uauduauduauduauduava0ava0ava0ava0ava0avqmavqmavqmavqna1qba1qba1qba1qba1qbqnqbqnqbqnqbqnqbqnqbudqbudqbudqca8t9zadmixqdcigaaaabjru5erkjggg=="}]