Whats wrong with this code… its showing wrong answer… No compilation error.
#include<iostream>
using namespace std;
int main()
{
int with;
double bal;
cin>>with>>bal;
if(with<bal)
{
if((with%5)==0)
{
bal=bal-with;
bal=bal-0.50;
printf("%.2f",bal);
}
else
printf("%.2f",bal);
}
else
printf("%.2f",bal);
}