Given daily prices and an integer k, find the maximum profit from at most k buy-then-sell transactions, then cut the extra memory as far as you can.
Unlock detailed company stats for this questionUpgrade
Given an array of daily prices and an integer k, find the maximum profit from at most k buy-then-sell transactions, holding at most one share at a time. Then reduce the extra memory your solution uses as far as you can.
Community answers
No answers contributed by the community yet.


