Report Bug

Quswhat will the output of : print(5&3) Qusइसका आउटपुट क्या होगा: print(5&3)


A. 1
B. 8
C. True
D. False


Solution
A. 1



Explanation

The & operator in Python performs bitwise AND operation. It takes the binary representations of two numbers and performs a bitwise AND operation on each pair of corresponding bits.

binary of 5 is : 101

binary of 3 is : 011

bitwise &    : 001 which 1 in decimal so the correct answer is 1

Latest Current Affairs 2025 Online Exam Quiz for One day Exam Online Typing Test CCC Online Test 2025 Python Programming Tutorials Best Computer Training Institute in Prayagraj (Allahabad) Best Java Training Institute in Prayagraj (Allahabad) Best Python Training Institute in Prayagraj (Allahabad) O Level Online Test in Hindi Bank SSC Railway TET UPTET Question Bank career counselling in allahabad Sarkari Naukari Notification Best Website and Software Company in Allahabad Sarkari Exam Quiz