summaryrefslogtreecommitdiff
path: root/progs/a508.py
blob: 646d681683ec239a9d2adb30e533e01cca9d831d (plain)
1
2
3
4
5
6
7
def max_Abs_Diff(arr,n): 
    minEle = arr[0] 
    maxEle = arr[0] 
    for i in range(1, n): 
        minEle = min(minEle,arr[i]) 
        maxEle = max(maxEle,arr[i]) 
    return (maxEle - minEle)