All right, everyone, welcome back to a new section.
In this section, we will see how to work with C
C++ files inside the obvious code.
Right.
So the first and the most trickiest thing to do is install
a C++ compiler in your device at home.
And this lecture, we will be following that installation
for Windows devices and for Mac and Linux.
I will be attaching some resources with this lecture
so you can go out and check out those resources.
Now, after that, we need to first check
whether a compiler is installed in our device on our IDE.
So you need to open up your terminal and here is your need to type in C++
best dash version and head and now have some successful.
And if something like this will appear, then congratulations.
You have a compiler installed.
Or if it does not, then don't worry.
Check out that option that is due to be Bethesda's version
and if any of them works then you are good to go.
Right.
So if you haven't installed compiler yet, then we are going to install the main
GW compiler for our C++.
Right.
So on my web browser I am on the main GW official site and let's
go to the download page where I will also attach the language, the resources.
Now here we are going to install the main GW files
and we need to go to the SourceForge website.
Now. This will download the file.
Basically. I don't want to download it.
I have already downloaded this and just simply open
this exit file
and then follow the instructions and basically install it.
By the way, I am not going to install this because this is going to take
a lot of time.
It is going to take around 20 to 1 an hour
depending upon your system configuration.
So if you want me, you can install the first method.
But there is a shortcut.
There is a hacky method to install the main GW compiler quickly and otherwise.
Right. So.
Right.
So you have this GW set up file
attached to this lecture and you can just simply install it.
You have to make sure that you install it in your C drive.
The location should be C drive.
So you need to first of all play set
anxiety or C drive and expect to see you drive.
Right?
So after extracting it, you will be getting a folder like this.
So the location will be C drive and mean GW And this is the second matter.
So this is the main GW compiler files.
And now basically we need to add this
bin folder to our environment variables.
So if you followed the first method,
then this same bin follow will be inside
some byte like inside your program files.
And when Gww 64 you need to click
and go to this location to open up your bin for it.
Right.
So now all we need to just added
as a bot in that environment variables.
And for that we need to go to start.
And here we need to type in environment variables.
And you can see you can simply click here.
After that we need to edit the environment variables
and we need to edit the bot.
So just simply click edit
and here you need to create a new part
and this new part you need to copy paste the location of your bin.
Follow. Right.
So let me just show you how to do this.
You can just simply copy paste this location.
You can simply copy it using Control Z and simply paste it here.
I have already paste it.
So after that you just simply click okay and okay
and close this bubble window.
Right. So after that, let's check.
After that, you need to check whether the compiler is installed or not.
So any of these commands and if you get a successful message, then congratulations,
You have your compiler installed and if it is not activated, send any kids.
You are having some issues with installing compiler.
Even in a mac clinic device and then you can just simply comment below.
I will be there to help.
Right.
So after installing the compiler, we need to also install
a couple of extensions to run C++
files easily in our base code. Right.
So the first extension would be C++ IntelliSense,
and you need to just simply type in C++ inside
your extension marketplace and first install this extension.
After that, I think that you already have called runner extension,
so this will help you to run your C++ files, right?
So as a backup, you need to also install
this C++ compiler and an extension because there might be some cases
when the code right now trial and error for your C++ files.
So for those cases, you can use this extension.
Now, after installing all of this, you are ready to go
and run C++ files and your device.
So in the next lecture we will see how to do it.