Why does greedy work here!?


#1

Why does greedy work here!?


#2

#3

IMO.Because we traverse the fibonacci series vector form end and thus selecting largest fibonacci number which is just smaller than given number ‘a’.