Can You Please give me the hint for this Question.
Can You Please give me the hint for this Question.
Please help
Can You Please give me the hint for this Question.
Can You Please give me the hint for this Question.
Please help
The idea is simple. You can try every cost in the given array one by one. The profit for each cost will be cost multiplied by the number of costs lower than or equal to it in the array.
And at each step, keep updating the result if it is greater than our answer.
Here is the implementation. Please check it.
Thanks Sir, Now Understood.
Welcome. Please mark your doubt as resolved now.
I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.
On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.