Skip to content

Only Code

Eat Code Sleep – repeat

  • Github
  • Home
  • Arrays
  • Linked Lists
  • Trees
  • Stacks
  • Queues
  • Heaps
  • Graphs
  • Algorithms+
    • Sorting
    • Dynamic Programming
    • Divide and Conquer
    • Backtracking & Recursion
    • Greedy approach
    • Breadth First Search (BFS)
    • Depth First Search (DFS)

Only Code

Eat Code Sleep – repeat

Close menu
  • Github
  • Home
  • Arrays
  • Linked Lists
  • Trees
  • Stacks
  • Queues
  • Heaps
  • Graphs
  • Algorithms+
    • Sorting
    • Dynamic Programming
    • Divide and Conquer
    • Backtracking & Recursion
    • Greedy approach
    • Breadth First Search (BFS)
    • Depth First Search (DFS)

Only Code

Eat Code Sleep – repeat

Search Toggle menu

Category: Algorithms

Minimum Spanning Tree (MST) | Kruskal’s Algorithm in C++

Kruskal’s algorithm is one of the popular algorithms used to find an MST in a connected weighted graph. This algorithm is efficient, easy to understand, and guarantees the construction of a minimum-weight spanning tree.

Algorithms, Graphs, Greedy approach

Bellman-Ford Algorithm | Single source shortest path

This algorithm uses Relaxation, to find the shortest path between the source vertex and other vertices. It gradually expands the search space until the shortest path to the destination node is found.

Algorithms, Dynamic Programming, Graphs

Dijkstra’s Algorithm | Single source shortest path

Dijkstra’s algorithm works based on the principle of Greedy-approach, gradually expanding the search space until the shortest path to the destination node is found.

Algorithms, Graphs, Greedy approach

Order Statistics | Selection Algorithm

“Order Statistics” is a concept discussed in the book “Introduction to Algorithms”. It pertains to finding the ith order statistics of a set of n elements in linear time. ith order statistics is the ith smallest element in a set of n elements.

Algorithms, Interview Questions

Non-decreasing Subsequences Solution – LeetCode Solution [Medium]

Given an integer array nums, return all the different possible non-decreasing subsequences of the given array with at least two elements.

Algorithms, Backtracking & Recursion, Competitive Programming

LRU (Least Recently Used) Cache | Algorithm & Implementation

LRU (Least Recently Used) Cache is a type of cache replacement algorithm, where the least recently used item is removed when the cache is full.

Algorithms, Special Data Structures

Data Structures for Disjoint Sets | Union Find Algorithm

This data structure is useful in situations where we need to group items together based on certain criteria, and then perform operations on these groups.

Algorithms, Special Data Structures

Coin Change II – LeetCode Solution [Medium]

You are given an integer array coins representing coins and an integer amount. Return the number of combinations that make up that amount.

Arrays, Competitive Programming, Dynamic Programming

Coin Change – LeetCode Solution [Medium]

You are given an integer vector coins[n] representing coins of different denominations and an integer amount representing a total amount of money.

Arrays, Competitive Programming, Dynamic Programming

Reservoir Sampling

Reservoir sampling is a category of randomised algorithms for choosing a simple random sample, without replacement, of k items

Algorithms, Interview Questions, Mathematics

Posts pagination

< 1 2 3 4 … 9 >
  • Algorithms
  • Arrays
  • Backtracking & Recursion
  • Breadth First Search (BFS)
  • C/C++
  • Competitive Programming
  • Computer Science
  • Data Science
  • Databases
  • Depth First Search (DFS)
  • Divide and Conquer
  • Dynamic Programming
  • Graphs
  • Greedy approach
  • Hashmaps
  • Heaps
  • Interview Questions
  • Java
  • Linked Lists
  • Machine Coding Questions
  • Machine Learning
  • Mathematics
  • Networking
  • Programming Projects
  • Python
  • Queues
  • Sorting
  • Special Data Structures
  • Stacks
  • Trees
  • Web Development
© 2025 Only Code | Aureolls
Exit mobile version