Getting wrong answer after submitting even when code seems correct

for this code I am getting wrong ,
this code is for ATM problem.

#include
#include
using namespace std;
int main()
{
int x;
float y;

cin>>x;
cin>>y;

if((x+0.50)<y&&x%5==0)
{

    y=y-(x+0.50);
}

cout<<fixed;
cout<<setprecision(2);
cout<<y;

return 0;

}