While and do while loop in C++

In this tutorial, we will learn how to execute statements repeatedly using ‘while and do while loop in C++’ , there difference and how and where to use them with examples. There may be a condition in where you  will need to execute a block of statement multiple times. Executing the same block of statement multiple time

for loop in C++

In this tutorial, we will learn how to execute statements repeatedly using for loop with examples. There may be a condition in which you need to execute a block of statement multiple times. Executing the same block of statement multiple time is called loop.  Syntax of for loop: for (initialization; test_condition; increment or decrement) { //block of

C++ Programming for beginners

History The C++ programming language was created by Bjarne Stroustrup and his team at Bell Laboratories (AT&T, USA). C++ reads as C plus plus was derived from C programming language. ++ denotes the increment operator in C meaning increment of C is C++.  C++ greatly influenced development of C# and Java. Characteristics of C++ C progarm

Input/Output in C programming

In this tutorial, we will learn about the ‘input output operation in C’. We will focus on the most commonly used functions of some standard library scanf() and printf(). Formatted Input: scanf() Scanf() function obtains data from input source, keyboard.   Syntax: scanf( format-control-string, other-arguments ); Example: double num; scanf("%lf", num); /* Wrong */ scanf("%lf", &num); /*

Structure and function in C programming

In this tutorial, we will learn how to pass structures as argument to a function and how to manipulate the structure. Functions and structure together helps to make the program in Object Oriented. Example : object-oriented program design. Consider a structurethat represents a complex number type. typedef struct { double real; double imag; } Complex; Construct

Strings and the Standard Library

In this tutorial, we will learn about the predefined function declared in the header file string.h. The standard library contains many functions for manipulating strings. Some of the functions: FunctionWork of Functionstrlen()Calculates the length of stringstrcpy()Copies a string to another stringstrcat()Concatenates(joins) two stringsstrcmp()Compares two stringstrlwr()Converts string to lowercasestrupr()Converts string to uppercase Above function will be