Write a function int solution(int A[], int that given an array A consisting of N integers, returns the sum of all integers which are multiples of 4
def solution(A):
sum=0
for i in A:
if i % 4==0:
sum+=i
return sum
A={5,5,2,8,3,88}
print(solution(A))
Comments
Leave a comment