CAN ANYONE TELL WHATS WRONG IN THIS SOLUTON FOR ATM?

https://www.codechef.com/viewsolution/41704044

Looks like you are completley new to competitive programming.
Rule of Thumb never add statments like “Enter the amount” and such.

Please refer to the How to get started page or look at the existing submissions by clicking on
All Submissions button.

PS. I am not commenting on your logic , since your whole program is wrong, because of those interactive statements.

1 Like

Thank
But I don’t think logic is wrong.
Thanks again for letting me know any interactive statement.

Take input according to the question. First withdraw amt. and then initial balance.

Logic is correct but you have to print according to the question for successful submission. Hopefully you can figure it out. :slight_smile:

Yes I understood and have submitted and got accepted. Thank you

:slightly_smiling_face::+1: