18 lines
466 B
Python
18 lines
466 B
Python
# Das Modul "math"
|
|
|
|
import math as m
|
|
|
|
# Einige wichtige Funktionen:
|
|
# exp(x) # return e**x
|
|
# log(a[,b]) # returns log of x to the base b
|
|
# sqrt(x) # Wurzel aus x
|
|
# pi # Zahl PI
|
|
# e # eulersche Zahl
|
|
# comb(n,k) # Binominalkoeffizient
|
|
# fabs(x) # returns absolut value of x
|
|
# gcd(a,b) # returns GGT
|
|
# pow(x,y) # berechnet x hoch y
|
|
|
|
# 2³ = 8
|
|
twoPower3 = m.pow(2, 3)
|
|
print("2³ =", twoPower3) |