ATM | CodeChef

After submitting, it is showing wrong answer. While it is giving the correct output. Can any one please tell me, what is wrong in given code?
#include<stdio.h>
int main(){
unsigned int X;
float Y;
scanf(“%d %f”,&X,&Y);
if(X<=2000 && Y>=0 && Y<=2000){
if(X<Y && X%5==0)
Y-=X+0.50;
printf(“%.2f\n”,Y);
}
return 0;
}

#include<bits/stdc++.h>
using namespace std;
int main()
{
int n;
float b;
cin>>n>>b;
if(n%5==0 && n<=(b-0.50))
{
b=b-n-0.50;
cout<<fixed<<setprecision(2)<<b;
}
else
{
cout<<fixed<<setprecision(2)<<b;
}
}

The same thing you have done in c++. But here I am using c language. But after submitting it is showing wrong answer.

#include<stdio.h>
#include<math.h>
int main()
{
int a;
float b,c,d;
scanf("%d%f",&a,&b);
if (b>a+0.5)
{
if (a % 5 ==0)
{
c = (b-a);
d=c-0.5;
printf("%.2f",d);
}
else
{
c = b;
printf("%.2f",c);
}
}
else{
printf("%.2f",b);

}
return (0);

}