You are given N cents (integer N) and have to break up the N cents into coins of 1 cent, 6 cents, 7 cents. Prove that greedy algorithm may not always give optimal solution
You are given N cents (integer N) and have to break up the N cents into coins of 1 cent, 6 cents, 7 cents. Prove that greedy algorithm may not always give optimal solution
Related questions
Question

Transcribed Image Text:You are given N cents (integer N) and have to break up the N cents into coins of 1 cent, 6 cents, 7 cents.
Prove that greedy algorithm may not always give optimal solution
Expert Solution

This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
Step by step
Solved in 3 steps
