@@ -21,9 +21,11 @@ c) Print − Prints the result.
2121d) Loop − Loops the above command until the user presses ctrl-c twice.
2222
2323like
24+ ``` ruby
2425$ node
2526> 1 + 3
26274
28+ ```
2729
28304 . Create the first application as Hellow world as.
2931Create folder day1--> go folder by Cd command -> Now type
@@ -49,35 +51,37 @@ console.log(obj.name);
4951
50522 . anonymous method
5153Function which is not having the name is called anonymous function.
52-
54+ ``` ruby
5355var v = function()
5456{
5557 console.log(" this is anonymous function" );
5658}
5759
5860v();
61+ ```
5962
60633 . Arrow function is based on arrow function keys
61-
64+ ``` ruby
6265var v = () => console.log(" this is arrow function" );
6366v()
64-
67+ ```
65684 . Multi line values Arrow function.
66-
69+ ``` ruby
6770var v = (a , b) =>
6871{
6972 console.log(" addition is :" );
7073 console.log(a + b);
7174};
7275
7376v(2 ,3 );
74-
77+ ```
7578
7679# Day 3 - Global Object
7780 In NodeJs Global Object, Object which we can be access by any modules.
7881
7982 We do not need to include these objects in our application, rather we can use them directly
8083
84+ ``` ruby
8185 // __dirname : it use to check the directive name.
8286console.log(__dirname )
8387
@@ -90,11 +94,13 @@ console.log("Satya")
9094// Require : include any out side module in page.
9195var requireTest = require (" ./requiretest" );
9296console.log(requireTest.abc);
97+
98+ ```
9399Creating your own module.
94100
95101Requiretest.js
96102
97- ========================================================
103+ ``` ruby
98104/ / Arrow function is based on arrow function keys/
99105
100106const name = " Satya Rathore" ;
@@ -103,14 +109,14 @@ v1();
103109
104110module .exports.abc = name;
105111
106- ========================================================
112+ ```
107113
108114Some other global object are
109115
110- //buffer
111- //module
112- //Reports
113- //Process
116+ - //buffer
117+ - //module
118+ - //Reports
119+ - //Process
114120
115121# Day 10 - ExpressJs
116122
0 commit comments