Amazing Solution with JS (^_^)
\n# Have fun with my code (^_^)\n\n/**\n * @param {string} encodedText\n * @param {number} rows\n * @return {string}\n */\nfunction decodeCiphertext(encodedText
\n# Have fun with my code (^_^)\n```\n/**\n * @param {string} encodedText\n * @param {number} rows\n * @return {string}\n */\nfunction decodeCiphertext(encodedText, rows) {\n  const col = encodedText.length / rows;\n  const arr = Array.from({ length: rows }, () => Array(col).fill(" "));\n\n  // fill 2d array with encodedText\n  let iter = 0;\n  for (let i = 0; i < rows; i++) {\n    for (let j = 0; j < col; j++) {\n      arr[i][j] = encodedText[iter++];\n    }\n  }\n\n  // get plainText from array 2d\n  let arrCol = 0;\n  let newStr = "";\n  while (arrCol < col) {\n    let j = arrCol;\n    let row = 0;\n    while (row < rows && j < col) {\n      newStr += arr[row][j];\n      row += 1;\n      j += 1;\n    }\n    arrCol += 1;\n  }\n  return newStr.trimEnd();\n}\n```
['JavaScript']