Commit e0ddf37b authored by winai buttasart's avatar winai buttasart

update homework week2

parent 4a06b423
const readline = require('readline');
// const fs = require('fs');
// const io = readline.createInterface({
// input: fs.createReadStream('package.json'),
// crlfDelay: Infinity
// });
// io.on('line', (line) => {
// console.log('data in line : ' + line);
// });
// io.close('close', () => {
// console.log('จบการรับค่า');
// });
const io = readline.createInterface({
input: process.stdin,
output: process.stdout
});
io.question('> ', (answer) => {
console.log(`สวัสดีคุณ ${answer}`);
io.close();
});
// console.info("hello word");
// console.log(`name = ${name}`);
\ No newline at end of file
{
"name": "student",
"version": "0.1.0",
"description": "display student information given nickname for partially entered fullname.",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1",
"start" : "node index.js"
},
"repository": {
"type": "git",
"url": "http://cs.sci.ubu.ac.th/b/Zt7yXa96XFPGXhvrg/node-js-60-2"
},
"keywords": [
"student",
"comsci",
"ubu",
"nodejs"
],
"author": "Nize",
"license": "ISC"
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment