Re: Taschenrechner fuer Konsole
Hi,
Torsten hat gesagt: // Torsten wrote:
> gibt es einen taschenrechner fuer die konsole?
Python natürlich.
Siehe dazu auch das Python Tutorial von Guido van Rossum:
3.1 Using Python as a Calculator
Da kann man sogar gleich mit komplexen Zahlen rechnen, richtige
Trigonometrie gibt's aber erst nach "from math import *":
>>> 3/2
1
>>> 3/2.0
1.5
>>> from math import *
>>> 3*sin(90)
2.6819899908016733
>>> 3*sin( abs( complex(0,1) ) )
2.5244129544236893
ciao,
--
Frank Barknecht _ ______footils.org__
Reply to: