Python Bitwise MCQs with Answers

Practice Python Bitwise MCQs with Answers provided below. The MCQ Questions for [current-page:node:field_class] Bitwise [current-page:node:field_subject] with answers and follow the latest [current-page:node:field_board]/ NCERT and KVS patterns. Refer to more Chapter-wise MCQs for [current-page:node:field_board] [current-page:node:field_class] [current-page:node:field_subject] and also download more latest study material for all subjects

MCQ for [current-page:node:field_class] [current-page:node:field_subject] Bitwise

[current-page:node:field_class] [current-page:node:field_subject] students should review the 50 questions and answers to strengthen understanding of core concepts in Bitwise

Bitwise MCQ Questions [current-page:node:field_class] [current-page:node:field_subject] with Answers

Question. What will be the output of the following Python code snippet if \( x=1 \)?
\( x << 2 \)

(a) 8
(b) 1
(c) 2
(d) 4
Answer: (d)
Explanation: The binary form of 1 is 0001. The expression \( x << 2 \) implies we are performing bitwise left shift on x. This shift yields the value: 0100, which is the binary form of the number 4.

Question. What will be the output of the following Python expression?
bin(29)

(a) ‘0b10111’
(b) ‘0b11101’
(c) ‘0b11111’
(d) ‘0b11011’
Answer: (b)
Explanation: The binary form of the number 29 is 11101. Hence the output of this expression is ‘0b11101’.

Question. What will be the value of x in the following Python expression, if the result of that expression is 2?
\( x >> 2 \)

(a) 8
(b) 4
(c) 2
(d) 1
Answer: (a)
Explanation: When the value of x is equal to 8 (1000), then \( x >> 2 \) (bitwise right shift) yields the value 0010, which is equal to 2. Hence the value of x is 8.

Question. What will be the output of the following Python expression?
int(1011)?

(a) 1011
(b) 11
(c) 13
(d) 1101
Answer: (a)
Explanation: The result of the expression shown will be 1011. This is because we have not specified the base in this expression. Hence it automatically takes the base as 10.

Question. To find the decimal value of 1111, that is 15, we can use the function:
(a) int(1111,10)
(b) int(‘1111’,10)
(c) int(1111,2)
(d) int(‘1111’,2)
Answer: (d)
Explanation: The expression int(‘1111’,2) gives the result 15. The expression int(‘1111’, 10) will give the result 1111.

Question. What will be the output of the following Python expression if x=15 and y=12?
\( x \& y \)

(a) b1101
(b) 0b1101
(c) 12
(d) 1101
Answer: (c)
Explanation: The symbol ‘\( \& \)’ represents bitwise AND. This gives 1 if both the bits are equal to 1, else it gives 0. The binary form of 15 is 1111 and that of 12 is 1100. Hence on performing the bitwise AND operation, we get 1100, which is equal to 12.

Question. Which of the following expressions results in an error?
(a) int(1011)
(b) int(‘1011’,23)
(c) int(1011,2)
(d) int(‘1011’)
Answer: (c)
Explanation: The expression int(1011,2) results in an error. Had we written this expression as int(‘1011’,2), then there would not be an error.

Question. Which of the following represents the bitwise XOR operator?
(a) \( \& \)
(b) \( \wedge \)
(c) \( | \)
(d) !
Answer: (b)
Explanation: The \( \wedge \) operator represent bitwise XOR operation. \( \& \) : bitwise AND, \( | \) : bitwise OR and ! represents bitwise NOT.

Question. What is the value of the following Python expression?
bin(0x8)

(a) ‘0bx1000’
(b) 8
(c) 1000
(d) ‘0b1000’
Answer: (d)
Explanation: The prefix 0x specifies that the value is hexadecimal in nature. When we convert this hexadecimal value to binary form, we get the result as: ‘0b1000’.

Question. What will be the output of the following Python expression?
0x35 \( | \) 0x75

(a) 115
(b) 116
(c) 117
(d) 118
Answer: (c)
Explanation: The binary value of 0x35 is 110101 and that of 0x75 is 1110101. On OR ing these two values we get the output as: 1110101, which is equal to 117. Hence the result of the above expression is 117.

Question. It is not possible for the two’s complement value to be equal to the original value in any case.
(a) True
(b) False
Answer: (b)
Explanation: In most cases the value of two’s complement is different from the original value. However, there are cases in which the two’s complement value may be equal to the original value. For example, the two’s complement of 10000000 is also equal to 10000000. Hence the statement is false.

Question. The one’s complement of 110010101 is:
(a) 001101010
(b) 110010101
(c) 001101011
(d) 110010100
Answer: (a)
Explanation: The one’s complement of a value is obtained by simply changing all the 1’s to 0’s and all the 0’s to 1’s. Hence the one’s complement of 110010101 is 001101010.

Question. Bitwise _________ gives 1 if either of the bits is 1 and 0 when both of the bits are 1.
(a) OR
(b) AND
(c) XOR
(d) NOT
Answer: (c)
Explanation: Bitwise XOR gives 1 if either of the bits is 1 and 0 when both of the bits are 1.

Question. What will be the output of the following Python expression?
\( 4 \wedge 12 \)

(a) 2
(b) 4
(c) 8
(d) 12
Answer: (c)
Explanation: \( \wedge \) is the XOR operator. The binary form of 4 is 0100 and that of 12 is 1100. Therefore, \( 0100 \wedge 1100 \) is 1000, which is equal to 8.

Question. Any odd number on being AND-ed with ________ always gives 1. Hint: Any even number on being AND-ed with this value always gives 0.
(a) 10
(b) 2
(c) 1
(d) 0
Answer: (c)
Explanation: Any odd number on being AND-ed with 1 always gives 1. Any even number on being AND-ed with this value always gives 0.

Question. What will be the value of the following Python expression?
bin(10-2)+bin(12\( \wedge \)4)

(a) 0b10000
(b) 0b10001000
(c) 0b1000b1000
(d) 0b10000b1000
Answer: (d)
Explanation: The output of bin(10-2) = 0b1000 and that of bin(12\( \wedge \)4) is ob1000. Hence the output of the above expression is: 0b10000b1000.

Question. Which of the following expressions can be used to multiply a given number ‘a’ by 4?
(a) \( a << 2 \)
(b) \( a << 4 \)
(c) \( a >> 2 \)
(d) \( a >> 4 \)
Answer: (a)
Explanation: Let us consider an example wherein a=2. The binary form of 2 is 0010. When we left shift this value by 2, we get 1000, the value of which is 8. Hence if we want to multiply a given number ‘a’ by 4, we can use the expression: \( a << 2 \).

Question. What will be the output of the following Python code if a=10 and b =20?
a=10
b=20
a=a\( \wedge \)b
b=a\( \wedge \)b
a=a\( \wedge \)b
print(a,b)

(a) 10 20
(b) 10 10
(c) 20 10
(d) 20 20
Answer: (c)
Explanation: The code shown above is used to swap the contents of two memory locations using bitwise X0R operator. Hence the output of the code shown above is: 20 10.

Question. What is the two’s complement of -44?
(a) 1011011
(b) 11010100
(c) 11101011
(d) 10110011
Answer: (b)
Explanation: The binary form of -44 is 00101100. The one’s complement of this value is 11010011. On adding one to this we get: 11010100 (two’s complement).

Question. What will be the output of the following Python expression?
\( \sim 100 \)?

(a) 101
(b) -101
(c) 100
(d) -100
Answer: (b)
Explanation: Suppose we have an expression \( \sim A \). This is evaluated as: -A – 1. Therefore, the expression \( \sim 100 \) is evaluated as -100 – 1, which is equal to -101.

MCQs for Bitwise [current-page:node:field_subject] [current-page:node:field_class]

Students can use these MCQs for Bitwise to quickly test their knowledge of the chapter. These multiple-choice questions have been designed as per the latest syllabus for [current-page:node:field_class] [current-page:node:field_subject] released by [current-page:node:field_board]. Our expert teachers suggest that you should practice daily and solving these objective questions of Bitwise to understand the important concepts and better marks in your school tests.

Bitwise NCERT Based Objective Questions

Our expert teachers have designed these [current-page:node:field_subject] MCQs based on the official NCERT book for [current-page:node:field_class]. We have identified all questions from the most important topics that are always asked in exams. After solving these, please compare your choices with our provided answers. For better understanding of Bitwise, you should also refer to our NCERT solutions for [current-page:node:field_class] [current-page:node:field_subject] created by our team.

Online Practice and Revision for Bitwise [current-page:node:field_subject]

To prepare for your exams you should also take the [current-page:node:field_class] [current-page:node:field_subject] MCQ Test for this chapter on our website. This will help you improve your speed and accuracy and its also free for you. Regular revision of these [current-page:node:field_subject] topics will make you an expert in all important chapters of your course.

FAQs

Where can I access latest Python Bitwise MCQs with Answers?

You can get most exhaustive Python Bitwise MCQs with Answers for free on StudiesToday.com. These MCQs for are updated for the 2026-27 academic session as per examination standards.

Are Assertion-Reasoning and Case-Study MCQs included in the [current-page:node:field_subject] [current-page:node:field_class] material?

Yes, our Python Bitwise MCQs with Answers include the latest type of questions, such as Assertion-Reasoning and Case-based MCQs. 50% of the paper is now competency-based.

How do practicing [current-page:node:field_subject] MCQs help in scoring full marks in [current-page:node:field_class] exams?

By solving our Python Bitwise MCQs with Answers, students can improve their accuracy and speed which is important as objective questions provide a chance to secure 100% marks in the .

Do you provide answers and explanations for Python Bitwise MCQs with Answers?

Yes, MCQs for have answer key and brief explanations to help students understand logic behind the correct option as its important for 2026 competency-focused exams.

Can I practice these [current-page:node:field_subject] [current-page:node:field_class] MCQs online?

Yes, you can also access online interactive tests for Python Bitwise MCQs with Answers on StudiesToday.com as they provide instant answers and score to help you track your progress in .