def solution(array): # Your code here