Skip to content

Latest commit

 

History

History
5 lines (3 loc) · 445 Bytes

File metadata and controls

5 lines (3 loc) · 445 Bytes

Linear Sequence

In general, the problems under this category fall under a similar problem scope as perfect-squares.md where the optimal answer can usually acquired by solving for every prefix/suffix of the array and then using the previously computed past states to compute the current state.

This is a combination of the trick to "re-frame the problem" and the recurrence pattern of "past states".