
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Found 7192 Articles for C++

584 Views
The const keyword in C++ is a keyword that is used to declare variables and objects as constant, which means the value declared using const cannot be changed or modified later, once they are initialized. This helps them prevent accidental modifications. For example, in a code, if we are using the value of PI, which has a fixed universal value and doesn't need any change, then we can declare it as a constant. When you declare the object with the const keyword, then the compiler places that value in ROM (Read-Only Memory), which protects it from being changed ... Read More

712 Views
In C++, variables can be declared as global or local depending on the scope of their declaration. Local variables are declared inside functions or blocks whereas global variables are declared outside all functions. Therefore their initialization behaviour also differs. In this article we will learn their different initialization behaviour in detail. Local Variable Initialization Local variables are the variables, which are declared inside a function or block (such as loops or conditionals) and are only accessible within that scope. By default local variables cannot initialize automatically, In case if you don't assign any value to that local variable, then it ... Read More

9K+ Views
C++ is a general-purpose, object-oriented programming language, which was developed by Bjarne Stroustrup at Bell Labs in the 1980s. It's an extension of the C language as it includes C features with additional object-oriented concepts like classes, inheritance, polymorphism, encapsulation, and abstraction.Before, it was known as "C with Classes" around 1979, but later renamed as C++ in 1983. These versions of the C++ language are compilers, which are implemented with the following rules made by the ISO C++ community, the community that looks over the development of the language. Here is the following list of C++ versions. ... Read More

1K+ Views
Both C and C++ are powerful programming languages that are used by developers to write both system-level and high-level programs. C language follows procedural programming paradigm with a simple and structured approach, whereas C++ supports both procedural and object-oriented programming. Although both C and C++ are widely used across various fields for developing different types of system and application software but they have different strength and use cases. In this article, we will learn when to use C over C++, and when C++ is a better choice than C. When to use C Language? When ... Read More

1K+ Views
Following are some of the differences between C and C++.When compared to C++, C is a subset of C++. All valid C programs are valid C++ programs.C is a structural or procedural programming language, while C++ is an object oriented programming language.In C, Functions are the fundamental building blocks, while in C++, Objects are the fundamental building blocks.C doesn't have variable references, while C++ has variable references.C uses malloc and free for memory allocation while C++ uses new and delete for memory allocation.C does not provide direct support for error handling, while C++ supports exception handling that helps in error ... Read More

308 Views
So you've decided to learn how to program in C++ but don't know where to start. Here's a brief overview of how you can get started. Get a C++ Compiler This is the first step you'd want to do before starting learning to program in C++. There are good free C++ compilers available for all major OS platforms. Download one that suits your platform or you can use the tutorialspoint.com's online compiler on www.tutorialspoint.com/compilers/online-cpp-compiler.htm GCC − GCC is the GNU Compiler chain that is basically a collection of a bunch of different compilers created by GNU. You can download ... Read More

3K+ Views
C++ is a general-purpose and high-level programming language, which was created by Bjarne Stroustrup in the early 1980s. It is an extension of the C programming language, which means it has features of C (procedural programming) with the added feature of object-oriented programming. It has become a widely used language, especially in competitive programming and is supported on most platforms such as Windows, Linux, Unix, and macOS. Advantages of C++ Programming LanguageIn this article we will discuss the advantages of using C++ language: C++ is a highly portable language that supports multi-device and multi-platform application ... Read More

1K+ Views
C++ is known to be a very powerful language. C++ allows you to have a lot of control as to how you use computer resources, so in the right hands, its speed and ability to cheaply use resources should be able to surpass other languages. Thanks to C++'s performance, it is often used to develop game engines, games, and desktop apps. Many AAA title video games are built with C++.C++'s greatest strength is how scalable it could be, so apps that are very resource intensive are usually built with it. As a statically typed language, C++ is generally more performant ... Read More

234 Views
C++ is a programming language developed by Bjarne Stroustrup in 1979 at Bell Labs. C++ is regarded as a middle-level language, as it comprises a combination of both high-level and low-level language features. It is a superset of C, and that virtually any legal C program is a legal C++ program. C++ runs on a variety of platforms, such as Windows, Mac OS, and the various versions of UNIX.It was designed with a bias toward system programming and embedded, resource-constrained and large systems, with performance, efficiency and flexibility of use as its design highlights. It has been used in the ... Read More

1K+ Views
To run the hello world program, you'll have to follow the following steps −Write a C++ programNow that you have a compiler installed, its time to write a C++ program. Let's start with the epitome of programming example's, it, the Hello world program. We'll print hello world to the screen using C++ in this example. Create a new file called hello.cpp and write the following code to it −#include int main() { std::cout