• Call Us : 03082533000 (WhatsApp)
  • Email Us : TestPointpk.com@gmail.com
Sticky Note
Which of the following is TRUE for a variable defined with the keyword const and initialized to a value in C language?
مندرجہ ذیل میں سے کون سا متغیر کے لئے صحیح ہے جو مطلوبہ الفاظ کے ساتھ بیان کیا گیا ہے اور سی زبان میں کسی قدر سے شروع کیا گیا ہے؟
  1. Can be overwritten within the scope of the variable
  2. Does not differ from the variable that is declared without const and initialized
  3. Cannot be changed within the scope of the variable during execution of the program
  4. Can be changed within the scope of the variable
Explanation

A variable declared with the const keyword in C becomes read-only and its value cannot be modified after initialization.

Attempting to change a const variable will result in a compile-time error.

Related MCQs

کمپیوٹر کا جسمانی حصہ کسے کہتے ہیں؟
  1. Software
  2. Hardware
  3. Both A and B
  4. None of these
اس سوال کو وضاحت کے ساتھ پڑھیں

کس قسم کے ٹرمینل میں اپنا پروسیسر ہوتا ہے اور جو آزادانہ طور پر حساب کتاب اور ڈیٹا پراسیس کر سکتا ہے؟
  1. Dumb Terminal
  2. Smart Terminal
  3. Intelligent Terminal
  4. None of these
اس سوال کو وضاحت کے ساتھ پڑھیں

سافٹ ویئر یا ہارڈ ویئر میں خرابی کو بگ کہا جاتا ہے۔ اس کے لیے متبادل کمپیوٹر جرگن کیا ہے؟
  1. Glitch
  2. Squid
  3. Slug
  4. None of these
اس سوال کو وضاحت کے ساتھ پڑھیں

سمورغ نامی سپر کمپیوٹر کس ملک نے تیار کیا ہے؟
  1. China
  2. Japan
  3. Iran
  4. None of these
اس سوال کو وضاحت کے ساتھ پڑھیں

سی پی یو کے اندر کون سی میموری نصب ہوتی ہے؟
  1. RAM
  2. ROM
  3. Register
  4. None of these
اس سوال کو وضاحت کے ساتھ پڑھیں

All Rights Reserved © TestPointpk.com