The option necessary to compile a C program havin math functions is . . . . . . . .
A. -lm
B. -ln
C. -lp
D. -lq
Answer: Option A
Solution (By Examveda Team)
This question is about compiling C programs that use mathematical functions.When you compile a C program, you need to link it with libraries that contain the necessary functions.
The -lm option tells the compiler to link the program with the math library.
This library includes functions like sqrt, sin, cos, and others for mathematical operations.
So the correct answer is Option A: -lm.
Let's look at why the other options are incorrect:
* Option B: -ln: This option is not related to the math library, it's likely used for other purposes.
* Option C: -lp: This option usually links to the standard C library, which contains basic functions but not the math functions.
* Option D: -lq: This option is not a standard library option in C programming.
Therefore, to compile a C program with mathematical functions, you need to use -lm to link the math library.
Related Questions on MySQL Miscellaneous
How is communication established with MySQL?
A. SQL
B. Network calls
C. A programming language like C++
D. APIs
Which type of database management system is MySQL?
A. Object-oriented
B. Hierarchical
C. Relational
D. Network

Join The Discussion