Ravi Ranjan has Published 148 Articles

C++ Program to Check Whether an Undirected Graph Contains a Eulerian Cycle

Ravi Ranjan

Ravi Ranjan

Updated on 28-May-2025 17:46:49

536 Views

The Euler path is a path by which we visit every edge exactly once while using the same vertices multiple times. When the starting and ending vertex of the Euler path is the same node (i.e., if a path starts from node 'A' and ends on node 'A'), it is ... Read More

C++ Program to Check Whether a Directed Graph Contains a Eulerian Cycle

Ravi Ranjan

Ravi Ranjan

Updated on 28-May-2025 12:12:00

636 Views

The Euler path is a path by which we visit every edge exactly once. We can use the same vertices for multiple times. The Euler Circuit is a special type of Euler path. When the starting vertex of the Euler path is also connected with the ending vertex of that ... Read More

C++ Program to Check Whether a Directed Graph Contains a Eulerian Path

Ravi Ranjan

Ravi Ranjan

Updated on 28-May-2025 12:11:45

523 Views

The Euler path is a path using which we can visit every edge exactly once in a graph. The same vertex can be used for multiple times. The source and destination nodes in the Euler path are different. If the source and destination node become the same, then the Eulerian ... Read More

C++ Program to Represent Graph Using 2D Arrays

Ravi Ranjan

Ravi Ranjan

Updated on 26-May-2025 18:32:31

2K+ Views

The graph can be represented using various ways. One of the technique is to use a 2D array, also known as adjacency matrix. The adjacency matrix is a square matrix of size V x V to represent a finite graph data structure using a 2D array, where V is the ... Read More

C++ Program to Generate a Random Directed Acyclic Graph (DAG) for a Given Number of Edges

Ravi Ranjan

Ravi Ranjan

Updated on 26-May-2025 18:29:29

662 Views

A Directed Acyclic Graph or DAG is a directed graph (a graph where each edge has a direction) that has no cycles present i.e. if we traverse along the direction of the edges then no closed loops are formed along any path. A DAG is always topologically ordered, i.e. for each ... Read More

C++ Program to Compute Discrete Fourier Transform Using Naive Approach

Ravi Ranjan

Ravi Ranjan

Updated on 26-May-2025 11:52:03

3K+ Views

DFT stands for Discrete Fourier Transform. DFT is a mathematical technique in which we convert the signals of the time domain to their respective signal in the frequency domain, i.e., converting into a list of numbers that tell us which frequencies are present in that signal. Here, by time signal, ... Read More

C++ Program to Compute DFT Coefficients Directly

Ravi Ranjan

Ravi Ranjan

Updated on 26-May-2025 11:51:43

321 Views

DFT stands for Discrete Fourier Transform. DFT is a mathematical technique in which we convert the signals of the time domain to their respective signal in the frequency domain, i.e., converting into a list of numbers that tell us which frequencies are present in that signal. Here, by time signal, ... Read More

Why C/C++ variables doesn’t start with numbers

Ravi Ranjan

Ravi Ranjan

Updated on 26-May-2025 11:51:12

2K+ Views

In C/C++, a variable name can have alphabets, numbers, and the underscore( _ ) character. There are some keywords in the C/C++ language. Apart from them, everything is treated as an identifier. Identifiers are the names of variables, constants, functions, etc. Why Variables in C/C++ Can't Start with Numbers? ... Read More

Initialization of a normal array with one default value in C++

Ravi Ranjan

Ravi Ranjan

Updated on 26-May-2025 11:39:09

18K+ Views

An array is a fixed-size collection of elements of the same data type that stores data in contiguous memory locations. Initializing an array with one default value in C++ is an easy task and can be easily implemented using various approaches that we are going to understand with code examples. ... Read More

How to “return an object” in C++?

Ravi Ranjan

Ravi Ranjan

Updated on 20-May-2025 19:38:05

5K+ Views

An object is an instance of a class. The memory is allocated only when an object is created and not when a class is defined. How to Return an Object in C++? An object can be returned by a function using the return keyword. There is no specific technique ... Read More

Previous 1 ... 7 8 9 10 11 ... 15 Next
Advertisements