modf()

modf(number) Return integer and fraction part of an input number.
modf(n)  

Example
import math
print(math.modf(23.45)) # (0.4499999999999993, 23.0)
print(math.modf(23))    # (0.0,23.0) 
print(math.modf(-12.34))# (-0.33999999999999986, -12.0) 
import math
print(math.modf(math.pi)) # (0.14159265358979312, 3.0) 


plus2net.com



Post your comments , suggestion , error , requirements etc here




We use cookies to improve your browsing experience. . Learn more
HTML MySQL PHP JavaScript ASP Photoshop Articles FORUM . Contact us
©2000-2020 plus2net.com All rights reserved worldwide Privacy Policy Disclaimer