Discover MakerZone

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

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!

Problem 2223. Cumulative difference

Created by Swapnali Gujar

Given an array, return the cumulative difference.

Example

 a = [ 1 3 5 7 ]
 cumdiff = [ 1 2 1 -2 ]

Tags

Problem Group

Solution Statistics

37 correct solutions 34 incorrect solutions
Last solution submitted on Oct 23, 2015

Problem Comments