Skip to content
Courses
DSA to Development
Get IBM Certification
Newly Launched!
Master Django Framework
Become AWS Certified
For Working Professionals
Interview 101: DSA & System Design
Data Science Training Program
JAVA Backend Development (Live)
DevOps Engineering (LIVE)
Data Structures & Algorithms in Python
For Students
Placement Preparation Course
Data Science (Live)
Data Structure & Algorithm-Self Paced (C++/JAVA)
Master Competitive Programming (Live)
Full Stack Development with React & Node JS (Live)
Full Stack Development
Data Science Program
All Courses
Tutorials
Data Structures & Algorithms
ML & Data Science
Interview Corner
Programming Languages
Web Development
CS Subjects
DevOps And Linux
School Learning
Practice
Build your AI Agent
GfG 160
Problem of the Day
Practice Coding Problems
GfG SDE Sheet
Contests
Accenture Hackathon (Ending Soon!)
GfG Weekly [Rated Contest]
Job-A-Thon Hiring Challenge
All Contests and Events
DSA
Practice Problems
Python
C
C++
Java
Courses
Machine Learning
DevOps
Web Development
System Design
Aptitude
Projects
Sign In
▲
Similar Topics
DSA
22.3k+ articles
Mathematical
7.7k+ articles
Arrays
6.4k+ articles
Strings
3.2k+ articles
Competitive Programming
2.3k+ articles
Algorithms
1.9k+ articles
Sorting
1.7k+ articles
Searching
1.7k+ articles
frequency-counting
730+ articles
array-rearrange
460+ articles
DSA
>
Algorithms
>
Greedy
Greedy
2k+ posts
Popular Articles
Recent Articles
Greedy Best first search algorithm
Last Updated: 18 January 2024
What is the Greedy-Best-first search algorithm?Greedy Best-First Search is an AI search algorithm that attempts to find the most promising p
...read more
Algorithms
Greedy
Technical Scripter
Picked
Technical Scripter 2022
DSA
Greedy Algorithms General Structure
Last Updated: 06 November 2024
A greedy algorithm solves problems by making the best choice at each step. Instead of looking at all possible solutions, it focuses on the o
...read more
Algorithms
Greedy
DSA
Split into K subarrays to minimize the maximum sum of all subarrays
Last Updated: 06 January 2025
Given an arrayarr[]and a numberk, split the given array intoksubarrays such that themaximumsubarray sum achievable out ofksubarrays formed i
...read more
Arrays
Binary Search
Greedy
Searching
subarray
DSA
Similar Topics
DSA
22.3k+ articles
Mathematical
7.7k+ articles
Arrays
6.4k+ articles
Strings
3.2k+ articles
Competitive Programming
2.3k+ articles
Algorithms
1.9k+ articles
Sorting
1.7k+ articles
Searching
1.7k+ articles
frequency-counting
730+ articles
array-rearrange
460+ articles
Find the sum of digits of a number at even and odd places
Last Updated: 10 October 2022
Given a number N, the task is to find the sum of digits of a number at even and odd places.Examples:Input: N = 54873Output:Sum odd = 16Sum e
...read more
Greedy
Mathematical
number-digits
School Programming
DSA
Practice Questions on Huffman Encoding
Last Updated: 28 December 2024
Huffman Encoding is an important topic from GATE point of view and different types of questions are asked from this topic. Before understand
...read more
Huffman Coding
Greedy
GATE CS
DSA
Find minimum number of currency notes and values that sum to given amount
Last Updated: 25 October 2024
Given an amount, find the minimum number of notes of different denominations that sum up to the given amount. Starting from the highest deno
...read more
Greedy
DSA
Huffman Decoding
Last Updated: 07 April 2023
We have discussed Huffman Encoding in a previous post. In this post, decoding is discussed.Examples:Input Data: AAAAAABCCCCCCDDEEEEEFrequenc
...read more
Algorithms
Greedy
DSA
Min and Max Costs to Buy All
Last Updated: 25 October 2024
In a candy store, there are N different types of candies available and the prices of all the N different types of candies are provided. Ther
...read more
Greedy
Sorting
DSA
Program for Best Fit algorithm in Memory Management
Last Updated: 13 September 2023
Prerequisite : Partition allocation methodsBest fit allocates the process to a partition which is the smallest sufficient partition among th
...read more
Greedy
memory-management
DSA
Maximum number possible by doing at-most K swaps
Last Updated: 28 April 2025
Given a string s and an integer k, the task is to find the maximum possible number by performing swap operations on the digits ofsat mostkti
...read more
Strings
Greedy
number-digits
DSA
Bin Packing Problem (Minimize number of used Bins)
Last Updated: 02 December 2024
Given n items of different weights and bins each of capacity c, assign each item to a bin such that number of total used bins is minimized.
...read more
Greedy
DSA
Minimize Cash Flow among a given set of friends who have borrowed money from each other
Last Updated: 24 April 2025
Given n number of friends who have to give or take some amount of money from one another. The task is to design an algorithm by which the to
...read more
Amazon
Graph
Greedy
DSA
Approximate solution for Travelling Salesman Problem using MST
Last Updated: 08 April 2025
Given a2d matrix cost[][]ofsize nwherecost[i][j]denotes the cost of moving fromcity i to city j.The task is to complete atourfromcity 0 (0-b
...read more
Graph
NPHard
Greedy
MST
DSA
Prim’s MST for Adjacency List Representation | Greedy Algo-6
Last Updated: 18 September 2023
We recommend reading the following two posts as a prerequisite to this post.Greedy Algorithms | Set 5 (Prim’s Minimum Spanning Tree (MST))
...read more
Graph
Greedy
MST
DSA
Applications of Minimum Spanning Tree
Last Updated: 12 October 2023
A Minimum Spanning Tree (MST) is a subset of the edges of a connected, undirected graph that connects all the vertices together, without any
...read more
Tree
Graph
Greedy
MST
DSA
First
1
2
3
4
5
6
7
8
>>
Last
First
1
2
3
4
5
6
>>
Last
First
1
2
3
4
>>
Last
We use cookies to ensure you have the best browsing experience on our website. By using our site, you acknowledge that you have read and understood our
Cookie Policy
&
Privacy Policy
Got It !