input two int and two float | print their sum and sub

#include<stdio.h>
#include<conio.h>
int main()
{
	int a,b,isum,isub;
	float x,y,sum,sub;
	scanf("%d%d",&a,&b);
	scanf("%f%f",&x,&y);
	isum=a+b;
	printf("%d",isum);
	isub=a-b;
	printf(" %d",isub);
	sum=x+y;
// float=25.00000 but when you use 1.1 ( float=25.0) 
	printf("\n%1.1f",sum);
	sub=x-y;
	printf(" %1.1f",sub);
	return 0;
}

Leave a comment