🚀 Hurry! Offer Ends In
00 Days
00 Hours
00 Mins
00 Secs
Enroll Now
X

1011 का आउटपुट क्या होगा?

What will be the output of: 1011 ?

A
13
B
12
C
Error
D
None
Explanation

The expression 1011 by itself (without any prefix or context) in Python is simply treated as a decimal integer.

print(1011)

Python इसे एक decimal number मानेगा — यानी:

➡ 1011 (base 10) = 1011

लेकिन अगर आप यह पूछ रहे हैं कि binary 1011 का decimal में क्या मान होगा, तो:

0b1011  → Binary literal

Then:

 
1×2³ + 0×2² + 1×2¹ + 1×2⁰
= 8 + 0 + 2 + 1 = 11

Correct Answer: D) None

Latest Updates