×
Home Discussions Write at Opengenus IQ
×
  • DSA Cheatsheet
  • HOME
  • Track your progress
  • Deep Learning (FREE)
  • Join our Internship 🎓
  • RANDOM
  • One Liner

Algorithms

Algorithms have proven to be the most important domain over the last century which has reformed the way we do tasks. It is actively used to design industry systems and forms the building blocks of companies like Google. We cover all types of algorithms in depth

Algorithms

Time & Space Complexity of Bellman Ford Algorithm

In this post, we do an analysis the Bellman Ford's single source shortest path graph algorithm to find its computational Time and Space complexity for Best case, Worst case and Average Case.

Erick Lumunge
Algorithms

Maximum String Partition problem: Partition Labels

In this article, we have explored approaches to solve the maximum string partition problem (Partition Labels) efficiently.

Kartik Keyan Kant Kartik Keyan Kant
Algorithms

Alien Dictionary problem: Sorted order of characters

In this article, we are given a sorted list of words in some alien dictionary. Based on the list, we have to generate the sorted order of characters in that alphabet. This problem can be solved using the idea of Topological Sort and Direct Acyclic Graphs.

J. Varun Iyer J. Varun Iyer
Algorithms

Shortest Superstring problem

In this article, we have explained three approaches to solve the Shortest Superstring problem. This involve concepts like DFS and Dynamic Programming.

Piyush Agrawal Piyush Agrawal
Algorithms

Swap Nodes in Pairs

In this article, we have explained an efficient approach to Swap adjacent nodes in a Singly Linked List inplace. We have presented both Iterative and Recursive implementation.

Ahmed Ossama Ahmed Ossama
Data Structures

All O`one Data Structure

In this post, we will design a Data Structure that returns the string occurring maximum and minimum times in constant time O(1). This will use a hashmap and a doubly linked list utilizing the advantages of each to solve the problem.

Erick Lumunge
Algorithms

Substring with Concatenation of All Words

In this article, we have explained two approaches to solve the problem Substring with Concatenation of All Words. This involves the idea of Hash Map and Two Pointer.

Joe Gorst Joe Gorst
Time Complexity

Time & Space Complexity of Heap Sort

In this article, we have explained Time & Space Complexity of Heap Sort with detailed analysis of different cases like Worst case, Best case and Average Case.

Akanksha Singh
Algorithms

Rotate Image: matrix of size NxN by 90 degrees (clockwise)

In this article, we have explored an efficient way to Rotate Image: matrix of size NxN by 90 degrees (clockwise) inplace by using a property of XOR operation.

Katia Kaori Kaminishikwahara Katia Kaori Kaminishikwahara
Algorithms

Reverse part of Singly Linked List

In this post, we have demonstrated ways in which we can not only reverse a singly linked list but also some part of Singly Linked List. It takes linear time O(N) to Reverse part of Singly Linked List.

Erick Lumunge
Algorithms

Remove N-th Node from end of Singly Linked List

In this article, we have explained two approaches to Remove N-th Node from end of Singly Linked List. We can do this in single pass / one traversal in O(N) time.

Erick Lumunge
List of Interview Questions

Interview Questions on Quick Sort

In this article, we have presented Interview Questions on Quick Sort (MCQ) with detailed answers. You must practice this as Quick Sort is the most important topic for Coding Interviews.

Ue Kiao, PhD Ue Kiao, PhD
Algorithms

Letter Combinations of a Phone Number

In this article, we have discussed two approaches (recursive + iterative) to solve the problem "Letter Combinations of a Phone Number" in C++ language with explanation of Time and Space complexity.

Kirti Singh
Algorithms

Roman to Integer

In this article, we have explained two efficient approaches / algorithms to convert Roman number to Integer. We have presented the implementation as well.

Erick Lumunge
Algorithms

Merge Intervals problem

In this article, we will learn how to solve the Merge Overlapping Intervals problem in most efficient and easy to understand method with the help of stack. We do this in linear time O(N).

Kartik Keyan Kant Kartik Keyan Kant
Algorithms

Number of Islands in MxN matrix (of 0 and 1)

In this article, we have explored an insightful approach/ algorithm to find the number of islands in MxN matrix. An extension of this algorithm is used by online battleship game engine.

Rohan Chandrashekar Rohan Chandrashekar
Algorithms

Flood Fill Algorithms

Flood Fill algorithm is an Algorithm that determines the area connected to a given node in a N-dimensional array. Some operations are performed on the connected nodes like color change. This is also known as Seed Fill Algorithm.

Piyush Agrawal Piyush Agrawal
Algorithms

Merge K sorted Linked Lists

We have explained 3 different algorithms to Merge K sorted Linked Lists such that the final Linked List is also sorted.

Akanksha Singh
Algorithms

K-th permutation of first N integers

In this article, we will understand and explore about the concept of generating k-th lexicographical permutation of first N integers. There are O(N!) permutations but you can find it in O(N) time.

Sanjana Babu
Algorithms

2 Sum Closest: Find 2 elements with sum closest to target

We have explained how to solve the 2 Sum Closest problem that is Find 2 elements with sum closest to a target efficiently. We have explained 3 different approaches which involves the use of Binary Search and Two Pointer technique.

Joe Gorst Joe Gorst
Algorithms

Recovering a Binary Search Tree that has two nodes swapped

In this article, we will be developing and implementing an algorithm that recovers a Binary Search Tree (BST) that had two of its nodes swapped accidentally.

Thompson Mina
Algorithms

ZigZag Conversion of String with N rows

In this article, we have solved the problem of ZigZag Conversion of String with N rows. We take a string and a number N (rows) as input and distribute the string in ZigZag fashion among N rows and print the final string.

Joe Gorst Joe Gorst
Algorithms

Karger’s algorithm to find Minimum Cut

In this article, we will explore how the Karger's algorithm works to find the minimum cut in a graph and its C++ implementation. This is a randomized algorithm based on Graphs.

J. Varun Iyer J. Varun Iyer
Algorithms

Maximum points on a line

In this article, we have explored an insightful approach/ algorithm to find the maximum number of points on a straight line. This problem finds many uses in computational geometry.

Rohan Chandrashekar Rohan Chandrashekar
Algorithms

Adjacency Matrices Explained: A Representation of Graphs

In this article, we have explained the idea of Adjacency Matrix which is good Graph Representation. We have presented it for different cases like Weighted, undirected graph along with implementation and comparison with Adjacency List.

Joe Gorst Joe Gorst
OpenGenus IQ © 2025 All rights reserved â„¢
Contact - Email: team@opengenus.org
Primary Address: JR Shinjuku Miraina Tower, Tokyo, Shinjuku 160-0022, JP
Office #2: Commercial Complex D4, Delhi, Delhi 110017, IN
Top Posts LinkedIn Twitter
Android App
Apply for Internship