#4: Node.js REPL Life Cycle Explained in Hindi with Practical Examples

Thapa Technical
63 followers
Nov 22, 2024
Hello what's up guys today in this video
we will see rail in nut j yes guys I
would like to tell you that our world best nut j
series has started we had recently
completed react version 19 so
now we are starting this nut version now If you have
n't checked it out till now, then
definitely check out the previous video. And today we are going to see
Rail, whose full form is Read Equal
Print Loop. Okay, so what is this, let me
tell you. Look guy, remember when we
installed our node
version yesterday, one thing I told you there was
that let's you come to the terminal,
okay you come to the terminal or you
come to the power cell here, that's it now. What you have to do
is to write node and if you write fun v then
first of all make sure that
this node is installed in your system. Make
sure that the node gets installed. In yesterday's video,
I told you two ways to
you can do whatever you want Okay,
after that if you write clear then it
becomes clear. Now here
you only have to write one thing that is node and you
don't have to do anything else just write node and then
you have to hit enter then everything is
clear. You can see that you have got a prompt
where it is saying welcome to nut dot jas
version this type help for more information is
ok dot help it is saying this if
I write this in this manner then
I don't have to All this is coming and then you
can see here at the end I can see an angle
bracket. This means that now you
are inside the evolution of the nut. Yes
guys, when you go to the terminal and
write a note in this manner. If you hit enter then you will
come inside the terminal of node JS. Basically
it's your entry right now. Now let's
pause it here for a while.
Now let's understand that when I wrote the note.
In what environment have I come, is it like a dark one, is this
some awesome future of Netflix's,
now I will tell you, listen carefully,
we have read this in full form, right now,
here he has written one thing very clearly,
read it carefully. It's an interactive
programming environment that allows
you to execute JavaScript code one
statement at a time. Yes guys, what do
you understand the moment you write a note and hit enter?
It means the environment that you are
getting, we call it
Rapal, yes guys, so this is the part that you are
seeing now in the terminal, I see it,
Control and then C and Control
and then C or Control D also you. If you can press
control twice, I am clearing it again.
The moment whenever you
write a note in your terminal, power cell, wherever you are,
earn promotion, you do it in Visual Studio code also,
wherever you go, just write the note. If
you hit enter, then after that
you get the item where you can go to the
script and write the code one at a time,
then that is called your rail, this
evolution that you have got, now it is
called your rail.
That's it, we are a repeater, I will tell you,
now here you see 2 + 2, your output has
come 3 * 3, see your 9 has come, okay, if you
want to use modus operator, you can do that,
but this modus No, this
is your division, here you can also write the code, for
now, I
do one thing here, look carefully, let's
construct array, I do one thing here,
I am making an array, okay. Look, I
am there, so the note is inside it is fine, in this way
I created an array, I will hit enter,
so now if I write AR, I am
getting an array, now in this array, I
show the map using map method. is
n't it like this From this I use a map
where there is nothing, I write '
Naam' or 'Naam', then one by one I will
get this 'Naam * 3' and I hit 'Enter',
then look, I am getting data here in this
way, so to say This means that whenever you
go to any terminal and
write node there and hit enter, you will
get an environment where you
can type JavaScript code,
then this development is called your rail. Now
here is one thing. These Okay, there are
more things here, look, I
told you that you can use it to test simple
JavaScript codes.
You can write simple JavaScript codes here
instead of going to the browser and console,
you can do this from end control. You can exit, now this
is the most important and I think
you will not get this in many courses
and that's it guys, this is Rail, the
first thing in this is your read, then comes
your read, then comes your print. And then
comes your loop, so what is happening here,
I will tell you, look carefully,
okay, then I will clear it once and
see, it is okay here, it is not getting cleared,
remove it, I will clear it here
now. Let me show it well, suppose
I write 2 + 2. Okay, what am I
going to do, I am writing 2 + 2 and I am
going to hit enter. I got the answer four,
so your rappel is hidden in it,
carefully. Listen to the moment you write 2 +
2 it means, now look carefully at this
wraparound, this particular
code, whatever code you wrote in the script, what did it
do with it, read it, what did it read and
pass it into where the data is.
Structure that the JavaScript engine can
understand, guys, what did he do, he
passed it to the read key and data structure
so that the JavaScript engine can understand
that brother, what is written, right after that, it is
evaluable at
now when read.
That data is passed to the JavaScript engine, then
what will the JavaScript engine do? It will evaluate the particular thing.
After all,
what does the user want? Well, 2+2 means if he
wants addition, then that
evaluation has been written for him. It is valid or not,
if it is valid then it will give the output, basically it will
pass and after that whatever output is
passed, it gets printed
and the same data is visible to you on your console,
so I have its information here. The data
appeared is four and after that, now the
same three process will continue on the loop,
again if you write 4 + 4 then
in the loop it is ready, read it is ok 4 + 4,
now it will read the loop read. After doing this,
it will pass it to the JavaScript engine, the
JavaScript engine will evaluate it,
see if this expression is valid,
then what it will do with its output, it will print it
and then it will run on the loop again, so guys,
this is Is your ripple, where is this thing that
you are feeling, then child 2+ 2 but in
behind the scene, first this is your raid,
then after passing it, it is passed to the Jas cut engine, is
its
evaluation valid or not? If it is valid,
then you get output on your console
and then loop again.
Ready to continue when someone
gives some expression, I read it and evaluate it. If I
print the data, in this way
it is called your rappel, this entire
environment where you are
able to write the code of JavaScript, this is your Rails and the
full form of Rails means this,
so I hope that today in this video
Now finally, this was your doubt, papal, that
you will never forget the
meaning of Rail in actual, till now no one has even
told this, everyone says this, write node and
hit enter, you are in Rail, where But you
can write code in JavaScript. But I
hope finally now you know that
you can write code in Rails. That's it. Now in tomorrow's
video I will tell you
what is CL and can you use Rails there.
I can also I ca
n't I can't but for that you will
have to wait and guys I
want if you see press control D you
will come out in one go so guys
how did you like the video let me know in the Comment section and
nut As this series is very important, React
version 19 has been recently finished,
please check it out and I
would like to tell you that guys, I
told you in a pre-requirement that whatever happens, you
need to know JavaScript, especially your
one script, please, this is mine. This is the world
best JavaScript course,
definitely watch it. Share it with your friends
because guys, I have created 28 hours of JavaScript. Do you
understand that the like views
are very less and the content I have created. I have
posted it here, if you see it once then I will write it and
give
you that content. If you don't find big institutes, I will give you that content by writing it.
Watch it once. I will be very happy. And
how did you like today's video? And finally, what was there was, I
hope. That whole doubt got cleared and
in life you are not going to say that
what was this after all and why was it
called like this, it is okay to say it so guys
I will meet you in tomorrow's video but
before that if you liked the video then please like.
Please do share with your friends as much as you can
and our next target is 7 lakh
subscribers and very close guys
please subscribe, a
red bell icon will also appear on the right side,
hit that too so that the daily notification at 4:00 pm I will
upload the video, don't miss it
and many more awesome videos are yet to come.
Ok guys, I will meet you in tomorrow's
video till then guys. Thank you so much.
Care
[Music]
