
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Divya Sahni has Published 42 Articles

Divya Sahni
168 Views
Problems involving grids and matrices are mostly solved using either BFS or DFS traversal algorithms. Taking a look into the first one, Breadth First Traversal − BFS or Breadth First Traversal is an algorithm for searching a tree or a graph data structure. It starts at the root node and ... Read More

Divya Sahni
230 Views
Reducing an array to a single element by repeatedly removing element is done by the following criteria − Select indices i and j such that i < j and arr[i] < arr[j] and convert one of the two elements to 0. Problem Statement Given an array arr[] containing positive integers. ... Read More

Divya Sahni
129 Views
Recurrence Relation − In mathematics, recurrence relation refers to an equation where the nth term of the sequence is equal to some combination of the previous terms. For a recurrence relation where each term equals the product of previous K terms, let’s define N and K along with an array ... Read More

Divya Sahni
192 Views
A subarray is a contiguous part of an array i.e. it can be considered as an array inside another array. For example, take the following array, array[] = {1, 2, 3, 4, 5, 6} For the above array, one possible subarray is subarry[] = {2, 3, 4} ... Read More

Divya Sahni
171 Views
The N-ary tree is a tree data structure where each node can have a maximum of N children where N is a positive integer (N >= 0). N-ary trees are used in many applications like file systems, organisational charts and syntax trees in programming languages. Example of N-ary tree with ... Read More

Divya Sahni
279 Views
The Shortest Path Faster Algorithm is an improved or more optimized version of the Bellman-Ford Algorithm. It calculates the single source's shortest path in a weighted directed graph. This algorithm is especially suitable for graphs with negatively weighted edges. Algorithm Given a weighted directed graph and a source vertex ... Read More

Divya Sahni
227 Views
Even-Odd Tree − A binary tree is called an even-odd tree if all the nodes at the even level (taking root node at level 0) have even values and all the nodes at the odd level have odd values. Problem Statement Given a binary tree. The task is to check ... Read More

Divya Sahni
94 Views
Level of a Binary Tree − In a binary tree, the level of the node refers to its distance from the root node. The root node is considered at level 0, its immediate children are at level 1, their children at level 2 and so on. Levels of a binary ... Read More

Divya Sahni
124 Views
Array insertion and reversal are one of the most common array manipulation techniques. Array manipulation aims to modify an array's contents to get a desired outcome. Problem Statement Given an input array A[]. The task is to insert the elements of the given array into an existing array where a ... Read More

Divya Sahni
1K+ Views
Pthreads is an execution model that helps use multiple processors to work at the same time for solving a problem. It is independent of the programming language. Problem Statement Given an array of integers. Find the sum of all the elements of the array using pthreads. Need for Multithreading for ... Read More