You are viewing a single comment's thread. Return to all comments →
JS
const l = s.length; const words = Math.ceil(Math.sqrt(l)); const letters = Math.floor(Math.sqrt(l)); const d = Number.isInteger(Math.sqrt(l)) ? 0 : 1; let r = ''; for(let i =0; i<words; i++) { for(let j = i; j < l; j += letters + d) { r += s[j]; } r += ' '; // 1 space } return r;
Seems like cookies are disabled on this browser, please enable them to open this website
Encryption
You are viewing a single comment's thread. Return to all comments →
JS