Which of the following is correct syntax for defining Mathematical constant PI using preprocessor directive in C language?
- # define PI 3.14
- # define PI = 3.14
- define PI = 3.14
- None of these
Explanation
#define PI 3.14
This is the correct syntax for defining a constant using the C preprocessor directive.
It replaces every instance of PI with 3.14 before compilation begins.
Related MCQs
میگا بائٹ سے بڑی اکائی کون سی ہے؟
- Gigabyte
- Kilobyte
- Byte
- Bit
اس سوال کو وضاحت کے ساتھ پڑھیں
کون سا میل ویئر نیٹ ورک کے ذریعے خودکار طور پر ایک کمپیوٹر سے دوسرے کمپیوٹر میں پھیل سکتا ہے؟
- Trojan Horse
- Worm
- Logic Bomb
- Spyware
اس سوال کو وضاحت کے ساتھ پڑھیں
ایڇ۔ٹی۔ٹی۔پی۔ایس کی اصطلاح کا کیا مطلب ہے؟
- Hyper Text Transfer Protocol Secure
- Hyper Text Translation Protocol Service
- Hyper Text Translation Protocol Secure
- Hyper Text Transfer Protocol Service
اس سوال کو وضاحت کے ساتھ پڑھیں
کیپچا کا بنیادی مقصد کیا ہے؟
- To speed up website loading times
- To verify that the user is human
- To improve image quality
- To block internet access
اس سوال کو وضاحت کے ساتھ پڑھیں
درج ذیل میں سے کون سا پرنٹر نہیں ہے؟
- Pixel printer
- Laser
- Dot matrix
- Inkjet printer