Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Tinh tong hieu tich thuong 2 so
- // Khai bao cac ham thu vien chuong trinh
- #include<stdio.h>
- #include<conio.h>
- void main()
- {
- int a,b;
- scanf("%d%d",&a,&b);
- printf(" Tong 2 chu so: %d\n",a+b);
- printf(" Hieu 2 chu so: %d\n",a-b);
- printf(" Tich 2 chu so: %d\n",a*b);
- if(a==0||b==0)
- {
- printf("0");
- }
- else
- {
- printf(" Thuong 2 chu so: %.2f",(float)a/b);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement