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

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

32 correct solutions 29 incorrect solutions
Last solution submitted on Nov 30, 2014

Problem Comments