My issue
int main() {
int x,y;
scanf(“%d %d”,&x,&y);
if(x%5==0 && y>=x+0.50)
{
printf(“%d”,y-(x+0.5));
}else{
printf(“%d”,y);
}
}
My code
#include <stdio.h>
int main() {
int x,y;
scanf("%d %d",&x,&y);
if(x%5==0 && y>=x+0.50)
{
printf("%d",y-(x+0.5));
}else{
printf("%d",y);
}
}
Learning course: Algorithmic Problem Solving
Problem Link: https://www.codechef.com/learn/course/klu-problem-solving/KLUPS00/problems/HS08TEST