Generate a program in Python for summing up the elements of an array.
[1, 4, 6]
def sumArrayElements(arr):
    total = 0
    for num in arr:
        total += num
    return total

arr = [1, 4, 6]
result = sumArrayElements(arr)
print(result)