1
1
mirror of https://github.com/theoludwig/programming-challenges.git synced 2024-11-09 22:08:58 +01:00
programming-challenges/templates/solution/javascript/solution.js

16 lines
322 B
JavaScript
Raw Normal View History

import readline from 'readline'
const input = []
const readlineInterface = readline.createInterface({
input: process.stdin,
output: process.stdout
})
readlineInterface.on('line', (value) => {
input.push(value)
})
readlineInterface.on('close', solution)
function solution() {
console.log(`Hello, ${input[0]}!`)
}