Appearance
let readline = require('readline') let rl = readline.createInterface({ input: process.stdin, output: process.stdout, }) // 监听输入,翻转字符串 rl.on('line', function (line){ let str = line.split('').reverse().join('') console.log(str) })
HJ12 字符串反转