Function to calculate any permutation divisible by 8. If such permutation exists , the function will return that permutation else it will return - 1
function isSubSeqDivisible ( str ) { let i , j , k , l = str . length ; let arr = [ ] ;