Home
last modified time | relevance | path

Searched refs:Rat (Results 1 - 2 of 2) sorted by relevance

/third_party/python/Lib/test/
H A Dtest_binop.py25 """Test whether an object is an instance of the Rat class."""
26 return isinstance(x, Rat)
28 class Rat(object): class
35 """Constructor: Rat([num[, den]]).
39 raise TypeError("Rat numerator must be int (%r)" % num)
41 raise TypeError("Rat denominator must be int (%r)" % den)
50 """Accessor function for read-only 'num' attribute of Rat."""
55 """Accessor function for read-only 'den' attribute of Rat."""
60 """Convert a Rat to a string resembling a Rat constructo
[all...]
H A Dtest_long.py542 class Rat: class
584 if not isinstance(other, Rat):
585 other = Rat(other)
612 Rx = Rat(x)
614 Ry = Rat(y)

Completed in 3 milliseconds