give integer array num integer k modify array follow waychoose index replace numsi numsiyou apply process exactly k time you choose index multiple timesreturn large possible sum array modifying way example 1input num 423 k 1output 5Explanation Choose index 1 num 423example 2input num 3102 k 3output 6explanation Choose index 1 2 2 num 3102example 3input num 23154 k 2output 13explanation Choose index 1 4 num 23154 Constraints1 numslength 104100 numsi 1001 k 104