what is problem with this code ? problem code is the last one of the beginners section.

#include <stdio.h>

int main( )
{
int x,y,a;
scanf("%d,%d",&x,&y);
if((x%5==0)&&(y>=(x+0.50)))
{
a=y-(x+0.50);
printf("%d",a);
}
else
printf("%d",y);

return 0;

}

Hey I guess u are asking the solution for problem “ATM”.

The mistake u did was took “int” in the place of “float”.For more detail about float Press here

Additionally I would like to add,while u are printing the answer use “%.2f” this will limit the answer to two decimals

Here is a link to my code.

thank you