
C++ is a high-level, general-purpose programming language developed by Bjarne Stroustrup in 1983 as an extension of the C language. It supports object-oriented programming (OOP), procedural programming, and generic programming, making it a versatile and powerful tool for a wide range of applications, from system-level software to large-scale applications.
1-Update the System
sudo apt-get update
sudo apt-get upgrade
2-Install the GNU Compiler Collection (g++)
sudo apt-get install g++ -y
3-Verify the Installation:
g++ –version
4-Write a Test C++ Program
a-Create a new file named arabtechai.cpp
nano arabtechai.cpp
b-Add the following code:
include <iostream>
using namespace std;
int main() {
cout << "Hello, this is my first program on C++" << endl;
return 0;
}
C-save the file:
Press Ctrl + O
to save.
d-exit the file
Press Ctrl + X
to exit.
5-Compile the C++ Program
g++ arabtechai.cpp -o arabtechai
6-Run the Program
./arabtechai