Help me in ZCO14001 (Video Game)

Hello, I have tried to submit a solution for the following problem:-
PROBLEM
SOLUTION

SUBTASK Result


Can someone please help and point out where and what I am doing wrong? It would be really helpful.

Instead of break use continue except last condition

@admin5
Well I did as you suggested.
This happened.
SUBTASK RESULT

You are getting WA because you didn’t check that crane already have a box or not before drop.
According to your code if 2 consicutive drop command occur this will increase stack with 2 which is wrong

Yes that might be the reason…I definitely didn’t think about that!!
Thanks.

Make a flag variable to check, crane already have a box or not

FINALLY Done! Thanks @admin5