Dynamic programming is applicable to problems with optimal substructure and overlapping subproblems.
Dynamic programming is applicable only to problems with optimal substructure.
Dynamic programming is applicable only to problems with overlapping subproblems.