if sum of its digits is equal to given sum , print it
if ( sum == 0 ) { out [ index ] = ' \0 ' ; for ( let i = 0 ; i < out . length ; i ++ ) document . write ( out [ i ] ) ; document . write ( " " ) ; } return ; }