If bit is set append '5' else append '4'
var bit = mask & rank ; if ( bit ) { left += y ; right += y ; } else { left += x ; right += x ; } } right = right . split ( ' ' ) . reverse ( ) . join ( ' ' ) ; return left + right ; }