Tuesday 2 October 2018

node.js: process.stdout: Write to standard output

'process.stdout' returns a stream that connected to stdout (Standard Output). Once you got the reference to standard output, you can write the data to it.

HelloWorld.js
process.stdout.write("Hello World\n");
process.stdout.write("Welcome to node.js programming");

Output

Hello World
Welcome to node.js programming



Previous                                                 Next                                                 Home

No comments:

Post a Comment