Whats wrong with my code?

Hi Akash
So there were 2 mistakes in ur code.
image
Here it should be cin>>a[i];
Secondly
image
here loop will start from i=1 and not i=0
I have corrected ur code.

thank you understood

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.