Function to update a value in the input array and segment tree . It uses updateValueUtil ( ) to update the value in segment tree
def updateValue ( arr : List [ int ] , st : List [ int ] , n : int , i : int , new_val : int ) -> None : NEW_LINE