Function to return the length of the largest sub - array of an array every element of whose is a perfect number
function contiguousPerfectNumber ( arr , n ) { let current_length = 0 ; let max_length = 0 ; let i ; for ( i = 0 ; i < n ; i ++ ) {