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

Python में pow(2, 3, 5) का परिणाम क्या होगा?

What will be the result of pow(2, 3, 5) in Python?

A
1
B
2
C
3
D
8
Explanation
The pow() function in Python, when provided with three arguments, calculates (base ** exponent) % modulus.
 
In the given expression pow(2, 3, 5):
 
  • base is 2
  • exponent is 3
  • modulus is 5
First, 2 ** 3 is calculated, which equals 8.
Then, 8 % 5 is calculated, which is the remainder when 8 is divided by 5. This remainder is 3.
 
Therefore, the result of pow(2, 3, 5) in Python is 3.
 
The correct answer is (c) 3.

Correct Answer: C) 3

Latest Updates