初次学习c语言

时间:2022-11-25 07:42:43

#include<stdio.h>

main(){      int o,p,q;

scanf("%d%d",&o,&p);

q=o+p; printf("%d",q);

scanf("%d%d",&o,&p); q=o*p;printf("%d",q); scanf("%d%d",&o,&p);

q=o/p; printf("%d",q); scanf("%lf%lf",&o,&p);

q=o+p; printf("%lf",q);

scanf("%lf%lf",&o,&p); q=o*p;printf("%lf",q); scanf("%lf%lf",&o,&p);

q=o/p; printf("%lf",q); }