Arithmetic Operations | C Programming Tutorial

preview_player
Показать описание
Рекомендации по теме
Комментарии
Автор

In my case, the power operator didn't work when I went to compile, so after some research I found that I needed to include -lm at the end of my gcc command to link the math library to my executable file. Just FYI if anyone else is stuck with this too

Cao
Автор

if we have
int a = 5;
printf("%d - %d", ++a, ++a);
why the output displays 7 - 7 ??
and printf("%d - %d", ++a, a++); outputs 7 - 5 ??

does the calculation happen from the far right first like when assigning values to variables?

zizou