Introduction to C++
C++ is a widely used middle-level programming language.
- Supports different platforms like Windows, various Linux flavours, MacOS etc
- C++ supports OOPS concepts like Inheritance, Polymorphism, Encapsulation and Abstraction.
- Case-sensitive
- C++ is a compiler based language
- C++ supports structured programming language
- C++ provides alot of inbuilt functions and also supports dynamic memory allocation.
- Like C, C++ also allows you to play with memory using Pointers.
Why you should learn C++?
- Many databases like MySQL, MongoDB, MemSQL, etc are written in C++
- C and C++ are used in developing major operating systems such as Windows, Linux, Android, Ubuntu, iOS etc.
- C++ has large community support.
- C++ is used in writing compilers, web browsers, Games and even in embedded systems.
- C++ developers are offered with high salaries.
- C++ is considered as a foundational language to learn advanced programming languages.
Why C++ is popular?
- C++'s greatest strength is it's scalability and hence challenging 3D games are often built in C++.
- C++ is fourth popular language according to Tiobe Index
- Applications which are critically reliable on speed and resource usage are usually preferred to be built in C++.
- Good community support.
Installation
1. on MacOS
- Install Xcode from Appstore.
- Once installed, accept the terms and conditions and provide your MAC password.
- Now, components will get installed.
2. on Windows
- There are many C++ compilers available in the market which are free to use.
- Download C++ compiler from VS-C-andC++
- Run the executable file.
3. on Linux
- Most Linux operating systems are pre-installed with GCC.
gcc -version
- For Ubuntu and Debian, use the below command
sudo apt-get update
sudo apt-get install GCC
sudo apt-get install build-essential
- For redhat, use the below command
yum groupinstall 'Development Tools'
4. Using Onecompiler
- You don't need to install any software or compiler.
- Just goto OneCompiler and choose the programming language as C++ and enjoy programming without any installation.