Pls tell the error in this code

u do not have to do so much

for maximum value just subtract 1st & last element
2nd and 2nd last element and so on
do not add to another vector

and to get minimum value
subtract adjacent values for each 2numbers

okay thank u ma’am…

1 Like