give integer array num return maximum difference successive element sort form if array contain element return 0you write algorithm run linear time use linear extra space Example 1input num 3691output 3explanation the sorted form array 1369 36 69 maximum difference 3example 2input num 10output 0explanation the array contain 2 element return 0 Constraints1 numslength 1050 numsi 109