Cody

# Problem 44073. Fractal: area and perimeter of Koch snowflake

Solution 1253843

Submitted on 20 Aug 2017 by Chris Cleveland
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
side = 10; nth = 0; Area_correct = 43; Perimeter_correct = 30; [myArea,myPerimeter] = KochSnowFlake(side,nth) assert(isequal(myArea, Area_correct)) assert(isequal(myPerimeter, Perimeter_correct))

myArea = 43 myPerimeter = 30

2   Pass
side = 10; nth = 1; Area_correct = 58; Perimeter_correct = 40; [myArea,myPerimeter] = KochSnowFlake(side,nth) assert(isequal(myArea, Area_correct)) assert(isequal(myPerimeter, Perimeter_correct))

myArea = 58 myPerimeter = 40

3   Pass
side = 10; nth = 20; Area_correct = 69; Perimeter_correct = 9460; [myArea,myPerimeter] = KochSnowFlake(side,nth) assert(isequal(myArea, Area_correct)) assert(isequal(myPerimeter, Perimeter_correct))

myArea = 69 myPerimeter = 9460