The first step is Download Node.js in the following website https://nodejs.org/en/download/ , choose the version according your operating system.
To write and compile our code we will use Notepad++, download it on the following website https://notepad-plus-plus.org/downloads/ .
After the first step complete we will make our “Hello World!” program.
Open Notepad++ an write the following code:
Then save your file as “Hello.js”.
Your Notepad++ file must look like this:
The next step is to open Node.js Command Prompt and type the following command and press enter.
The “path_of_the_file” is the directory where you saved your Notepad++ file (Hello.js).
The image below will ilustrate it better:
After the directory change we will type the following command:
This command will run the statement on the notepad++ file and show the output on the Node.js command prompt as it is shown on the image below.
Thats how we create our first program in Node.js.