Форум — Development поблемы с некоторыми функциями.... 0 0 когда вызываются ф - и типа sqrt, fmod и дт при компиляции вылетает undefined referense, причем math.h в инклуде присутствует... никто не подскажет , что делать? Ссылка
[1][lg:pn][~/tmp]$ cat t.c #include "math.h" main() { printf("%f\n", pow(2, 4)); } [0][lg:pn][~/tmp]$ gcc -o t t.c /tmp/ccOdOuYB.o: In function `main': /tmp/ccOdOuYB.o(.text+0x22): undefined reference to `pow' [1][lg:pn][~/tmp]$ gcc -o t t.c -lm [0][lg:pn][~/tmp]$ ./t 16.000000 [10][lg:pn][~/tmp]$ lg ★★ (04.09.02 20:20:38 MSK) Показать ответ Ссылка
Ответ на: комментарий от lg 04.09.02 20:20:38 MSK Не ответ! Но меня смущают две вещи: #include "math.h" main() { printf("%f\n", pow(2, 4)); } исправить на #include <stdio.h> #include <math.h> main() { printf("%f\n", pow(2, 4)); } anonymous (09.09.02 20:39:43 MSK) Ссылка