Maximum Value of an Ordered Triplet II at Media.net
Medium56.4% acceptance
This problem has 87.5% frequency at Media.net.
Problem Description
You are given a **0-indexed** integer array `nums`. Return _**the maximum value over all triplets of indices**_ `(i, j, k)` _such that_ `i < j < k` _._ If all such triplets have a negative value, return `0`. The **value of a triplet of indices** `(i, j, k)` is equal to `(nums[i] - nums[j]) * nums[...
Read full problem and hintsTopics
Also asked at 4 companies
More Media.net Questions
Minimum Total Space Wasted With K Resizing OperationsMediumDifference Between Maximum and Minimum Price SumHardCount the Number of Square-Free SubsetsMediumTrapping Rain Water IIHardMaximum Genetic Difference QueryHard
View all Media.net questions