3rd Dec 2018, 2:03 PM
Suraj yadav
Suraj yadav - avatar
2 Respostas
+ 1
Ok
4th Dec 2018, 12:38 PM
Suraj yadav
Suraj yadav - avatar
0
1. Modify the data type of your input variables to int as you read them with %d int a, b, c; 2. Modify reading input ( one input per line I think that is better) from scanf("%d%d",&a,&b); to scanf("%d\n %d\n",&a,&b); Have in mind that the a/b maybe returns float number so check if c variable should be float and cast the result as follow : c = (float) a / b;
3rd Dec 2018, 3:03 PM
Prokopios Poulimenos
Prokopios Poulimenos - avatar