

McqMate
Q. |
What is the value of the following Python expression? bin(0x8) |
A. | ‘0bx1000’ |
B. | 8 |
C. | 1000 |
D. | ‘0b1000’ |
Answer» D. ‘0b1000’ | |
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’. |
View all MCQs in
Problem Solving and Python ProgrammingNo comments yet