Cody

Problem 1448. Create Volcano (or Atoll) martix. It is an extension of Bullseye matrix problem.

For example, if n=2 (maximum value), the output matrix should be

 [1 1 1 1 1;
  1 2 2 2 1;
  1 2 1 2 1;
  1 2 2 2 1;
  1 1 1 1 1]

where you go from inside to outside starting from 1 to 2(maximum value) and again move back from 2 to 1.

Solution Stats

63.49% Correct | 36.51% Incorrect
Last solution submitted on Dec 09, 2016

Problem Comments

Solution Comments

Tags

Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

MATLAB Academy

New to MATLAB?

Learn MATLAB today!

Join the 15-year community celebration.

Play games and win prizes!

Learn more