An interval is a contiguous subarray from index i to index j, inclusive. The length is j. I + . In interval DP, you typically iterate by length.
First solve all intervals of length (base cases), then length , then length , up to the full array. The answer you want is usually or , depending on whether you use -indexed or -indexed arrays. Understanding this concept will help you solve more complex problems.