Dsa
Dynamic Programming
Easy
Max Product Subsequence
Given an array of integers, find the maximum product you can get by multiplying elements of a non-empty subsequence. A subsequence is any sequence derived from the array by deleting some elements without changing the order of the remaining elements. Your task is to find and return the maximum product. If all numbers are negative, return the largest negative number. Input: A list of integers. Output: An integer representing the maximum product of any non-empty subsequence. Example: Input: [3, 1, 5, 0, 2] Output: 30.
Key concepts
dynamic_programmingsubsequencearray
Practise this out loud — free
Start a mock interview on THIS exact question — a voice AI interviewer opens with it, pushes back like a real onsite, then hands you an instant scorecard.
🎙 Practise this question now