पायथन गणित.ldexp () विधि
उदाहरण
x * (2**i) का रिटर्न मान:
#Import math Library
import math
#Return value of x * (2**i)
print(math.ldexp(9, 3))
print(math.ldexp(-5, 2))
print(math.ldexp(15,
2))
परिभाषा और उपयोग
यह math.ldexp()
विधि दी गई संख्याओं x * (2**i) को x और i लौटाती है, जो कि
math.frexp() का व्युत्क्रम है ।
वाक्य - विन्यास
math.ldexp(x, i)
पैरामीटर मान
Parameter | Description |
---|---|
x | Required. A positive or negative number. If the value is not a number, it returns TypeError |
i | Required. A positive or negative number. If the value is not a number, it returns TypeError |
टेक्निकल डिटेल
प्रतिलाभ की मात्रा: | x * का मान (2**i) |
---|---|
पायथन संस्करण: | 2.6 |