Use of this keyword in stack

do we really need to use this keyword while pushing the data into a stack?
can’t it be simply be written as array name[top]=value without writing this keyword ?

Yes you can but it is advised to use this to avoid confusion about which variable you are accessing.

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.