i don’t understand the approach behind finding inc and dec array and using max(int[i]+dec[i]-1.
What is logic behind writing{max(inc[i] + dec[i]-1)}. why it is giving the longest bitonic subarray
Refer to this video . It explains the required approach
Also work with some sample cases following this approach to understand clearly
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.