×
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

Merge two sorted linked lists

In this article, we will learn how to Merge two sorted linked list such that the final linked list is also sorted in linear time O(N).

Kartik Keyan Kant Kartik Keyan Kant
Algorithms

Longest Common Prefix

In this article, we are going to explore different approaches to find the longest common prefix between two strings. Same techniques can be applied to find the Longest Common Prefix for multiple strings.

Thompson Mina
Algorithms

4 Sum problem

In this article, we have explored an insightful approach/ algorithm to find the 4 elements in an array whose sum is equal to the required answer (4 Sum problem). This concept finds many uses in computational geometry.

Rohan Chandrashekar Rohan Chandrashekar
Algorithms

Implement K stacks in one array

In this article, we have present two approaches to design K stacks in one array. The challenge is to efficiently store the elements to use all available space in the array and maintain the time complexity of stack operations.

Vikram Shishupalsingh Bais Vikram Shishupalsingh Bais
Algorithms

Longest substring without repeating characters

In this article, we have explained three approaches to the problem of finding Longest substring without repeating characters. This involves the use of Hash Map with the clever use of start and end index.

Akanksha Singh
Algorithms

Integer to Roman Numeral Conversion

In this article, we have presented the algorithm to Convert Integer to Roman Numerals along with C++ implementation and step by step implementation.

Katia Kaori Kaminishikwahara Katia Kaori Kaminishikwahara
Algorithms

Closest 3 Sum problem (Find all triplets close to the given sum)

In this article, we have explored an insightful approach/ algorithm to find the 3 elements in an array whose sum is equal to or close to the required answer. This is an extension of the 3 Sum problem where the resulting sum needed not be exact.

Rohan Chandrashekar Rohan Chandrashekar
Algorithms

Number of Ordered Solution Pairs (X, Y) satisfying 1/X + 1/Y = 1/N

We have explored two insightful approaches/ algorithms to find the Number of Ordered Solution Pairs (X, Y) satisfying 1/X + 1/Y = 1/N. This problem is used extensively in Astrophysics.

Rohan Chandrashekar Rohan Chandrashekar
Algorithms

Different ways to calculate Pi (3.14159...)

We have covered different algorithms and approaches to calculate the mathematical constant pi (3.14159...). These include Nilakantha Series, Leibniz’s Formula, Ramanujan's Pi Formula and other Programming Language specific techniques.

Kartik Keyan Kant Kartik Keyan Kant
Algorithms

Median of two sorted arrays

In this article, we have presented 3 Algorithms to find the Median of two sorted arrays efficiently in logarithmic time. This involves a clever use of Binary Search algorithm.

Akanksha Singh
Algorithms

Two Sum Problem: Check if pair with given sum exists [Solved]

In this article, we have explained different approaches to solve the Two Sum Problem using techniques like Binary Search, Hash Map and others.

Ue Kiao, PhD Ue Kiao, PhD
Algorithms

Hill Climbing Algorithm

We will learn how the hill climbing algorithm works for local searching. This algorithm is a heuristic search algorithm, a concept prominently explored in areas of Artificial Intelligence (AI).

J. Varun Iyer J. Varun Iyer
Algorithms

Bin Packing problem

Bin Packing problem involves assigning n items of different weights and bins each of capacity c to a bin such that number of total used bins is minimized. It may be assumed that all items have weights smaller than bin capacity.

Rohan Chandrashekar Rohan Chandrashekar
Data Structures

Data Structure with insert and product of last K elements operations

We have presented 2 designs for Data Structure with insert and product of last K elements operations. Both operations can be done in constant time O(1).

Vikram Shishupalsingh Bais Vikram Shishupalsingh Bais
Algorithms

Intersection of two arrays

We have explored several approaches to find Intersection of two arrays efficiently. This involve techniques like sorting, binary search, hash map and much more.

Akanksha Singh
List of Mathematical Algorithms

Number of integers between 1 and N that are coprime to N

We have explored efficient approaches to find Number of integers between 1 and N that are coprime to N. We have presented the idea of Euler φ (phi) function and is an important topic to get hold on Mathematical Algorithms.

Rohan Chandrashekar Rohan Chandrashekar
Algorithms

Fast and slow pointer technique in Linked List

We have explained Fast and slow pointer technique in Linked List which is also known as tortoise and hare algorithm. It is used to efficiently solve several problems by using two pointers.

Abhishek Singh
Algorithms

Finding the twin primes up to N (Twin Prime Conjecture)

We will learn about prime numbers and the twin prime conjecture. We will also look at an efficient algorithm for finding the first twin prime pairs up to a number N.

Thompson Mina
Algorithms

Implement Bubble sort in a list in Python

We have explained the basic of Bubble Sort along with a detailed explanation of Python implementation of Bubble Sort in a list.

Akanksha Singh
Algorithms

Count total set bits in all numbers from 1 to N

We have presented an efficient approach to find the total number of set bits in all numbers from 1 to N in O(logN) time by deriving a pattern and a formula.

Vikram Shishupalsingh Bais Vikram Shishupalsingh Bais
Algorithms

Integer Factorization Algorithms

We have explored in great detail some of the different factorization algorithms for Integers such as Trial Division, Pollard's rho algorithm, Dixon's algorithm and Quadratic Sieve.

Sanjana Babu
Algorithms

Longest Increasing Consecutive Subsequence

We have to find the Longest Increasing Consecutive Subsequence in N elements. We can solve this problem efficiently using Dynamic Programming in O(N) time.

Vikram Shishupalsingh Bais Vikram Shishupalsingh Bais
Algorithms

Find Peak Element in an Array

We have explained the problem of finding Peak Element in an Array along with different approaches to solve it efficiently.

Fahd Agodzo Mohammed Fahd Agodzo Mohammed
Data Structures

Design data structure that support insert, delete and get random operations

We will understand in depth the designing of a data structure that supports "insert value", "delete value" and "get random" operations where these tasks are performed in constant time O(1).

Sanjana Babu
Algorithms

Majority Element in an array

We have discussed algorithmic techniques to find the majority element in an array. The brute force algorithm takes O(N^2) time while the most efficient algorithm can do it in O(N) time.

Tushti
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