Python numphy Jak używać ułamków
from fractions import Fraction
num1=Fraction(1, 3)
num2=Fraction(1, 7)
print(num1*num2)
Nazário
from fractions import Fraction
num1=Fraction(1, 3)
num2=Fraction(1, 7)
print(num1*num2)
import fractions
print(fractions.Fraction(1.5))
print(fractions.Fraction(5))
print(fractions.Fraction(1,3))
from fractions import Fraction
frac = Fraction(1, 2)