+ 2

NOTICE

there is a mistake in the format in this example it should be %f not %d #include <stdio.h> #define VERY_LONG_CONSTANT \ 23.678901 #define MAX 100 #define MIN 0 # define SQUARE(x) \ x*x int main() { printf("%d\n", VERY_LONG_CONSTANT * SQUARE(2)); return 0; }

2nd Dec 2019, 6:33 PM
Nouhayla Erraou
Nouhayla Erraou - avatar
3 Respostas
+ 3
Erraou Nouhayla Yes you are right. There should be %f not %d. If you run that Example which is given here in the 4th section exception is coming. https://www.sololearn.com/learn/C/2957/
2nd Dec 2019, 7:00 PM
A͢J
A͢J - avatar
+ 2
Where is Example? Please provide full information.
2nd Dec 2019, 6:35 PM
A͢J
A͢J - avatar
0
I edited my notce, this code is from the course
2nd Dec 2019, 6:40 PM
Nouhayla Erraou
Nouhayla Erraou - avatar