Sudhir sharma has Published 1149 Articles

Euler Method for solving differential equation in C++

sudhir sharma

sudhir sharma

Updated on 22-Jan-2021 13:00:01

5K+ Views

In this problem, we are given a differential equation f(x, y) = dy/dx with initial value y(x0) = y0. Our task is to find the solution of the equation using the Euler method for solving differential equations.EULER METHODEuler method also known as forward euler Method is a first order numerical procedure to find ... Read More

Equilibrium index of an array in C++

sudhir sharma

sudhir sharma

Updated on 22-Jan-2021 12:59:42

621 Views

In this problem, we are given an array arr[] consisting of n integer values. Our task is to create a program to find the equilibrium index of an array.Equilibrium Index is the index at which the sum of all elements before the index is the same as the sum of all ... Read More

Equidigital Numbers in C++

sudhir sharma

sudhir sharma

Updated on 22-Jan-2021 12:59:30

151 Views

Equidigital numbers are mathematically special numbers in which the number of digits in the number is equal to the number in its prime factorization.In this problem, we are given an integer value n. Our task is to create a program to all equidigital numbers up to n.Let’s take an example ... Read More

Equal Sum and XOR in C++

sudhir sharma

sudhir sharma

Updated on 22-Jan-2021 12:55:57

874 Views

In this problem, we are given an integer n. Our task is to create a program to find the count of integers from i = 0 to n, where sum is equal to XOR i.e. (n+i) = (n^i).Let’s take an example to understand the problem, Input:  n = 4Output: 4Explanation: Considering all ... Read More

Equalize an array using array elements only in C++

sudhir sharma

sudhir sharma

Updated on 22-Jan-2021 12:55:44

448 Views

In this problem, we are given an array of n elements. Our task is to create a program to count the number of operations to equalize an array using elements only.We need to count the number of adding or subtraction operations that will be performed to make all the elements ... Read More

Equable Shapes in C++

sudhir sharma

sudhir sharma

Updated on 22-Jan-2021 12:53:47

182 Views

In this problem, we are given the coordinates of a polygon. Our task is to create a program to check whether the given polygon is equable or not.Equable Shape is the shape whose perimeter is equal to the area of the shape.Let’s take an example to understand the problem, Input: polygon[][] = ... Read More

Enumeration of Binary Trees in C++

sudhir sharma

sudhir sharma

Updated on 22-Jan-2021 12:53:31

492 Views

Enumeration of Binary Tree is counting the total number of distinct unlabeled binary trees of a given size (specific number of nodes). In this article, we will create a program to count the number of Binary Trees of n nodes.Based on labeling of nodes of binary tree, it is of two ... Read More

Entringer Number in C++

sudhir sharma

sudhir sharma

Updated on 22-Jan-2021 12:49:29

167 Views

Entringer Number is a special number which is equal to the number of permutations of {1, 2, 3, … n+1}, starting with K+1 which is updated by decreasing then increasing the values alternatively.The value of Entringer Number is formulated using, The recurrence relation, E(n, k) = E(n, k-1) + E(n-1, n-k)The ... Read More

Endian order and binary files in C++

sudhir sharma

sudhir sharma

Updated on 22-Jan-2021 12:49:11

612 Views

In the binary file and data management, endianness is the sequence of bytes of a digital data inside the computer memory.In computer memory there are two type of endian order, Big-endian system stores the most significant byte of the data.Small-endian systems store the least significant byte of the data.Read More

Emulating a 2-d array using 1-d array in C++

sudhir sharma

sudhir sharma

Updated on 22-Jan-2021 12:48:54

345 Views

In this problem, we will understand the conversion of 2-D array to 1-D array. We will see how to store the elements of a 2-D array to a 1-D array.Here, the size of 1-D array is same as the total number of elements in 2-D array which is n*m.In programming ... Read More

Advertisements