In this post, we will implement a C++ program to check if a number is Multiply Perfect Number. What’s a Multiply Perfect Number? First, let us understand what is a Multiply-P.... Read More
Now let’s learn how to use Tree Rerooting Technique in C++. Problem description Consider an unweighted tree with N node and N-1 edges and a positive number D, Find how many d.... Read More
This problem is about a greedy algorithm we will going to solve this problem and will learn about the concepts and algorithm used and then will see its implementation in C++. Probl.... Read More
In this tutorial, we will learn how to convert a string into a character array in C++. There are multiple ways to convert a string to a char array in C++. Let’s discuss some .... Read More
Hello everyone, in this tutorial, we will learn about beta(), betaf() and betal() function in C++ STL. All these functions are defined in <cmath> header. These are built-in C.... Read More
In this article, we will learn how to find the median array for a Binary tree in C++. A median array is an array that formed with help of Inorder, Preorder, Postorder traversal of .... Read More
Now we will be going to solve a dynamic programming problem Long jumps in C++. Problem description A person is currently standing on point 0 in the 1-D array and jumps to reach poi.... Read More
Now let’s solve the Special item array problem Problem description There are several special items and the special item can be split to form M normal items. Both types of ite.... Read More