# What's wrong with my submission?

This is the problem : [ATM][1]

This is my submitted solution : [Solution][2]

[1]: https://www.codechef.com/problems/HS08TEST
[2]: https://www.codechef.com/viewsolution/13798260

@vijju123 are u here?

``````Input
50 50.00

-0.50

Expected Output
50.00 (as "If there is not enough money in the account to complete the transaction (+the bank fees), output the current bank balance.")``````
1 Like

1. Try to find details in the problem like when to use < and when to use <=.

2. You didn’t take into account the extra charges the bank requires of 0.05 for every transaction done. So your current balance should be withdrawl amount + \$0.05.

Solution -

Just change the following line of your code - if(x%5==0&&x<=y) to - if(x%5==0&&x+0.05<y)

1 Like

@vijju123, i corrected my solution. still WA. New Solution

No, its not correct. The total cost in my test case is 50.50, while balance had only \$50. Re-check the expected output

1 Like

got that.

You may need to change this condition-

“if(x%5==0&&x<=y)”

Make it check if her balance> withdrawing amount+0.5

1 Like

got AC. thanks

1 Like