Home General

General

This category lists the general description for the programming.

Binomial Coefficients in C++

How we implement a logic to find out the binomial coefficients of an entered number by the user in C++?. Look at the below code: # include <iostream> ...

Decrement operator overloading in C++

Decrement operator in C++ is used to decrease the value of a variable by 1 or some other fixed interval, normally it is used in loops. Now decrement operator can be...

Simple Java inheritance example

Inheritance is one of the most powerful feature of OOP. It provides us code reusability and polymorphism. The concept is very simple and similar to real life. It allows new classes to...

4 Big Mistakes to Avoid When Learning Programming

Here are the 4 big mistakes which you have to avoid while learning programming. 1) Fear and self doubt: I have put this in the first place because it's the...

McCarthy 91 function in C++

McCarthy 91 function is a recursive function used within computer science, its definition is: Now how we implement this McCarthy 91 function in our C++ code,  have a look at the below...

Recursive factorial function in C++

Here we are going to define our recursive factorial function in C++: #include <iostream> using namespace std; int factorial(int n) // 1, 1, 2, 6,...

Area and Perimeter of rectangle in C++

Area and Perimeter both are the mathematical terms used with rectangle, area is the length multiplied by width while perimeter is the length of all sides of the rectangle. Now how...

Overloading steam insertion and extraction operators in C++

For putting data into the stream and getting data from the stream, the stream insertion and extraction operators are used, Now these operators are already defined for defined datatypes in C++,...

Address Book program in C++

In C++ we can write an address book program that can store a person’s name and other related data, In this given source code, we are not using any file handling...

Creating a Calculator program in Java

Java, being a power full language, contributes in many technology fields. It has deep contribution in the modern world. A basic calculator program in java can perform logical computations and displays...