• 0

increment an integer array by one


Problem

Given an integer array, increment its numeric value by one.
For example,

increment([2, 7, 3]) returns [2, 7, 4]


Solution