Burst Balloons
Hard
Dynamic Programming
There are n balloons with values nums[i]. Bursting balloon i gives nums[i-1] * nums[i] * nums[i+1] coins (out-of-range neighbours count as 1). Print the maximum coins obtainable by bursting them all.
Constraints
1 <= n <= 300 0 <= nums[i] <= 100
Discussion
No discussions yet.
Shalyam Support
Hi! Ask us anything — we'll reply on WhatsApp or Telegram within 24 hours.