Python‎ > ‎Fraction‎ > ‎

Fraction.imag()

http://www.adilwaseem.com/

Definition
The real number without imaginary part.

Syntax
Fraction.imag()

Parameters


Examples
Here are output:
 >>> Fraction(.99).imag
0
>>> Fraction(1).imag
0
>>> Fraction(1.2).imag
0
>>> Fraction(2.1).imag
0

The return is:
 >>> Fraction(2.1).__eq__(Fraction(2.1).imag)
False



Comments