/*#include <stdio.h>
int main()
{
printf("Hello world!\n");
return 0;
}
//#include<stdio.h>
int main()
{
int d;
int h,m;
scanf ("%d",&d);
h=d/60;
m=d%60;
printf("%d %d",h,m);
return 0;
}
정수/정수 -> 정수
10 / 3 -> 3 (정수몫)
정수/실수
실수/정수 -> 실수
실수/실수
10.0 / 3 -> 3.333333 %f
3.33 %.2f
d / f ->
정수/정수 ->
(float)d / f ->
실수 / 정수 ->
강제형변환 : 정수 변수를 잠깐 실수로 바꿔라!
오버플로 : 넘쳐흘러버렸어!
int -> -2147483648 ~ +2147483647
int a = 3000000000; // -> 오버플로발생!!!!
//
#include<stdio.h>
int main()
{
int d,f;
scanf("%d %d",&d,&f);
printf("%d\n%d\n%d\n%d\n%d\n",d+f,d-f,d*f,d/f,d%f);
printf("%.2f",(float)d/f);
return 0;
}
//#include<stdio.h>
int main()
{
int s,d,f;
scanf("%d %d %d",&s,&d,&f);
printf("%d\n",s+d+f);
printf("%.1f",(float)(s+d+f)/3);
return 0;
}
*/
/*
#include<stdio.h>
int main()
{
int d;
scanf("%d",&d);
printf("%d",d*24);
return 0;
}
정수+정수=정수
"%d+%d=%d"
*/
/*
#include<stdio.h>
int main()
{
int d,f;
scanf("%d %d",&d,&f);
printf("%d+%d=%d\n",d ,f ,d+f );
printf("%d-%d=%d\n",d ,f ,d-f );
printf("%d*%d=%d\n",d ,f ,d*f );
printf("%d/%d=%d\n",d ,f ,d/f );
return 0;
}
@@ 산술연산자 + - * / %
정수 + 정수 -> 정수
@@ 비교연산자 > < >= <= == !=
정수 > 정수 -> 1 또는 0
a>b -> a가 b보다 큰가요? -> 1 또는 0
printf("%d",a>b); // -> 1 or 0
1. 비교연산의 결과는 무조건 1 또는 0으로만 나온다 !!!!
2. >= <= != " =을 오른쪽에 써야한다"
a>=b (o) a가b보다 크거나 같나요?
a=>b (x) a가 b와 같거나 큰가요?
컴퓨터가 못알아들음!!!
3. == vs =
a==5 (비교) a와 5가 같나요??
a=5; (대입) a는 5야.
*/
/*
#include<stdio.h>
int main()
{
int d,f;
scanf("%d %d",&d,&f);
printf("%d",d>f);
return 0;
}
*/
#include<stdio.h>
int main()
{
int d,f;
scanf("%d %d",&d,&f);
printf("%d",d==f);
return 0;
}