Can someone help me figure out the problem in my code?
Here is the question link
integer overflow here arr[i]*(n-i)
arr[i]*(n-i)