Computer AwarenessVery hardIBPS SO IT Officer

When two n-bit two's-complement numbers are added, overflow has occurred exactly when:

  1. A. Both operands have the same sign and the result has the opposite sign
  2. B. A carry comes out of the most significant bit position during the addition
  3. C. The operands have opposite signs and the result comes out negative
  4. D. The sign bit of the result is 1, whatever the signs of the operands

Correct answer: A. Both operands have the same sign and the result has the opposite sign

Overflow is possible only when both operands share a sign, and it shows as a result of the other sign. A carry out of the MSB alone is normal (e.g. −1 + 1) and is simply discarded.

हिंदी में

दो n-बिट टू’ज़-कॉम्प्लिमेंट संख्याएँ जोड़ने पर ओवरफ़्लो ठीक तब होता है जब:

  1. A. दोनों संकार्यों का चिह्न समान हो और परिणाम का चिह्न विपरीत हो
  2. B. जोड़ते समय सबसे महत्वपूर्ण बिट स्थान से कैरी बाहर निकले
  3. C. संकार्यों के चिह्न विपरीत हों और परिणाम ऋणात्मक आए
  4. D. परिणाम का साइन बिट 1 हो, संकार्यों के चिह्न चाहे जो हों

उत्तर: A. ओवरफ़्लो तभी संभव है जब दोनों संकार्यों का चिह्न समान हो, और यह विपरीत चिह्न के परिणाम के रूप में दिखता है। केवल MSB से कैरी निकलना सामान्य है (जैसे −1 + 1) और उसे छोड़ दिया जाता है।

More Computer Awareness questions

Exams that ask this topic