Find Maximum Profit

  You are given an integer array of prices where prices[i] is the price of a given stock on the ith day and an integer k. Find the maximum profit you can achieve. You may complete at most k transactions, where each transaction incurs a transaction fee as a percentage of the transaction amount. You may not engage in multiple transactions simultaneously (i.e., you must sell the stock before you buy again). Write a function to calculate the maximum profit considering the transaction fee. Parameters: K: An integer representing the maximum number of transactions allowed. prices: An array of integers representing the prices of the stock on each day. fee: A number representing the transaction fee as a percentage of the transaction amount.  

Comply today with Compliantpapers.com, at affordable rates

Order Now