C++ Preprocessor Directives
C++ Preprocessor Directives: A C++ preprocessor directives are the lines that are included in a program which begins with the # and it is different from the typical source code. …
C++ is an object-oriented programming language. It was the extension of C programming. C++ is a middle-level programming language which was developed by “Bjarne Stroustrup ” starting in 1979 at “Bell Labs“. It runs on a different type of platforms such as Windows, Mac OS, and also various versions of the Unix.
CPP tutorial has been defined for students, software engineers who are trying to learn in details regarding C++.
Before we start learning this language, we should have the basic idea of C programming. And also the basic understanding of computer programming.
This is multiparadigm that supports object-oriented programming. While It is regarded as a middle-level language in such a way it is a combination of both high -level and low-level language features.
And it is a general purpose, case-sensitive, statically typed, compiled programming language that supports object-oriented, procedural and generic programming. And also statically typed. It is used by programmers to create software programming.
C++ (or) cpp has a different type of uses as follows:
This language supports object-oriented programming, including the four pillars of the OOps in C++ as follows:
C++ Preprocessor Directives: A C++ preprocessor directives are the lines that are included in a program which begins with the # and it is different from the typical source code. …
C++ templates: The c++ template can be defined as a blueprint or formula for creating a generic class or a function. Templates are the foundation of generic programming, which involves writing …
Namespaces in C++: The namespace in C++ can be used to overcome the difficulty of using the same name for many times. And is used as additional information to differentiate …
C++ Files and Streams: In the C++ files and streams the operations are performed by using streams too. By using the file handling we can store our data in the secondary …
Multithreading in C++ is a specialized form of multitasking in which it allows your computer to run two (or) more programs concurrently. The thread classes and related functions are defined …
Dynamic Memory Allocation in C++ can be defined to perform memory allocation manually by the programmer. The dynamically allocated memory is allocated on Heap. All variables declared inside the function …
try, catch, throw exceptions in C++: In C++ exception handling can be done by using try, catch, throw keywords. In the previous session, we have already learned regarding exception handling occurrence …
Exception Handling in C++: The exception handling in C++ is the process to handle runtime errors. A C++ exception is a response to an exceptional circumstance that arises while a program …
C++ Enumeration (enum): It is a user-defined data type which can be assigned with some limited values. These values are defined by the programmer at the time of declaring the enumerated …
C++ Structs can be defined in such a way that classes and structs are blueprints that are used to create the instance of a class. (or) A Struct is a …
C++Encapsulation: It is a process of wrapping of data and methods in a single unit. It is achieved in the C++ language by the class concept. The Combining state and …
C++ Abstraction: Abstraction shows important things to the user and hides internal details. And hiding of data is known as “data abstraction“. Data abstraction can be used to provide security for …
C++ Polymorphism: Polymorphism is derived from the Greek words. Poly means “many” and “morphism” means “forms” i.e many forms. Polymorphism means more than one form. The operation depends upon the types …
Friend class and Friend function in C++: A friend class can access private and protected members of other classes in which it is declared as a friend. And in sometimes …
Types of Inheritance in C++: As we have already learned regarding inheritance in the previous articles. Let us learn about the different types of inheritances present in C++. Types of Inheritance …
C++ Inheritance: Inheritance is the process in which the objects of one class can acquire the properties of another class. And also it supports the concept of hierarchical classification. And …
C++ overloading can be defined as a technique to use a single identifier to define various methods or techniques of a class that differs in their input and output parameters. …
The destructors in C++ can be defined as a member function which destructs or deletes an object. The destructor names are the same as the class name but they are …
C++ Constructors: Constructors in C++ can be defined as a special member method which will be called implicitly (automatically) whenever an object of a class is created. In other words, …
OOPs Concept in C++: The major purpose of C++ programming is to introduce the OOPs (Object Oriented Programming language) concept in C++ language. Object-oriented programming is a paradigm in which it …
C++ this Pointer: In the C++ language, this is a keyword that refers to the current instance of the class. There are three main uses for using this keyword. They …
C++ Pointer Arithmetic: This can be used to perform arithmetic operations on pointers. And there are totally four arithmetic operators present in C++ are ++, – -, + and -. The …
Difference between Arrays And Pointers in C++: As we have already learned about the arrays and pointers in the previous articles. Lets us know the difference between them. Difference between Arrays …
Pointer to Pointer in C++: This can be defined as a form of multiple indirections or a chain of pointers. Normally, a pointer contains the address of a variable. When we …
Array of pointers in C++: This can be defined as an array is a list or holding tank for a set of values. Once those values are set it’s very hard to …
Pointers in C++ can be defined as a variable whose value points to the address of another variable. Pointers can dynamically allocate the memory. While the pointer variable holds the …
String manipulation in C++: The manipulation of strings in C++ can be defined as we have already learned that C++ will not support the built-in string type. So, we have …
String Operations in C++ can be used to make the work easier by using the functions in short form of commands. And we are having different types of operations in …
String Functions in C++: There is a different type of functions on strings. They are as follows: Input Functions Capacity Functions Iterator Functions manipulating Functions And these functions of strings …
The C++ strings are nothing but used for representing a sequence of characters as an object. String class stores the characters as a sequence of bytes. A string is described …
Types of Arrays in C++: C++ allows us to create multidimensional arrays. There are different types of arrays in C++. They are as follows: One Dimensional Array Two dimensional Array …
The C++ arrays can be defined as a collection of items located stored at contiguous memory locations. Here, contiguous memory location means just after the first element of an array, …
Difference between function overloading and function overriding in C++: In the before sections, as we have already learned in detail regarding function overloading and function overriding. Now, let us learn …
C++ Function Overriding: It defines the same function as defined in its base class. This is known as “function overriding“. This was used for achieving run time polymorphism. It enables …
The C++ function overloading can be defined as if two (or) more function shaving the same name but different arguments are known as “function overloading“. And the overloaded functions must …
Difference between Call by value and Call by Reference in C++: As we have already regarding the call by value, reference, and address. Now let us learn the differences between …
Parameter Passing References in C++ Functions: The parameter passing references in C++ can be passed into and out of the functions. There are two different types of parameters in which function …
Member Functions in C++: Driving programs into a function are one of the major principles of programming. These are known as “Member functions” in C++. They have their deceleration’s inside the …
C++ Functions: The C++ functions can be defined as a group of statements that perform a particular task. And in every C++ program, there will be at least one function called …
C++ Nested Loops: In C++ nested loops are nothing but using a loop inside another loop is known as “Nested loops”. C++ allows nearly 256 levels of testing. Here, the …
C++ Infinite Loop: This loop can also be called as “endless loop”. This loop in C++ can be defined as a piece of code which lacks the exit such that …
C++ Do-while loop: In this loop the execution is terminated based upon the test condition. These are similar to while loops. We can also say that this loop is an exit-controlled …
C++ While loop: The C++ while loop repeats the statement until the condition is true. In this loop, we do not know no. of loops in before like the for …
C++ for loop: A C++ for loop can be used to iterate a part of a program structure several numbers of times. If the no.of iterations are fixed then it …
C++ Switch statements: The C++ switch statements allows us to test multiple conditions for the if statement. These statements are the substitute for long if statements that compare a variable to …
C++ Nested if statements: In this statement, it will be targeting the another if statement. And in simple words, we can also say that if statement inside another if statement. You …
C++ if else statement: The C++ if else statement helps when if statement executes false we can use the else statement for executing. It is also used to control the flow …
C++ if statement: The C++ if statement is a simple decision-making statement. It is used to check whether a certain block of statements will be executed (or) not. So, if a …
C++ Decision Control Statements are nothing but the decision making statements that decides the order of execution of statements based on conditions. These are also called as “Control Statements“. While …
Storage Classes in C++: The storage classes in C++ defines the scope and lifetime of a variables (or) functions within a program. Here, Lifetime refers to the period during which …
Variable Scope in C++: A variable scope in C++ is nothing but the scope of a variable can be defined as the extent of the programming code in which the code …
C++ Constants/ Literals: In C++ Constants/ Literals are nothing but they refer to fixed values. Their values cannot be changed once they are assigned. Constants can be of any of …
Operators in C++ can be defined as a symbol that is used to perform mathematical (or) logical operations. And in this language, we are having a rich set of built-in …
C++ Keywords: Keywords in C++ are nothing but a reserved words in C++ Library. We cannot use them as a variable names, constant names etc. C++ Keywords List List of …
Variables in C++ can be used to store data in the memory location and whose value can be changed during the program execution. C++ variables In C++ variables are case …
C++ Data Types: In C++ Data types are nothing but they used to store information in the computer memory with different data types. When a variable declares it is necessary …
Basic C++ Input Output: cin, cout, endl are used in the streams. A stream is nothing but a sequence of bytes (or) flow of data. Let us know in detail …
C++ Tokens: Tokens in C++ can be defined as the smallest building block (or) the smallest unit in C++ program. Each word and punctuation can be referred to as a …
C++ Manipulators: C++ Manipulators are nothing but functions that are designed to be used in the conjunction with the insertion(<<) and extraction(>>) operators on stream objects. C++ Manipulators Let us …
Structure of C++ program: In this section, we are going to learn regarding the structure of a C++ program with examples. Also, we have explained the terms used in the …
Comments in C++: Like all other programming languages we can also represent in C++. Comments are nothing but the explanatory statements that you can include in the code. Single Line Comments: …
Streams in C++: In this language input-output (io) is based on streams. C++ streams are nothing but the bytes which are flowing in and out of the programs. The input …
C++ Features: In this, we are going to learn the features of C++ i.e. the main features which make C++ more powerful than other languages. Features of C++ There are …
C++ Installation and setup: Before starting and going deep into the C++ program, let us know about the C++ installation and setup for compiling and executing the programs. C++ Installation …
Difference between C and C++: In this post, we are going to learn the differences between C and C++ programming languages. C programming language C++ Programming language It is a procedural …
C++ Introduction: In this C++ introduction, we are going to have a brief idea regarding this language. C++ was originally developed by “ Bjarne Stroustrup” in 1980 at “bell laboratories” …