Benutzer-Werkzeuge

Webseiten-Werkzeuge


python:loesungen:lingrog

Unterschiede

Hier werden die Unterschiede zwischen zwei Versionen angezeigt.

Link zu dieser Vergleichsansicht

Nächste Überarbeitung
Vorhergehende Überarbeitung
python:loesungen:lingrog [2020/05/16 14:57] – angelegt lutzpython:loesungen:lingrog [2020/05/16 14:59] (aktuell) lutz
Zeile 1: Zeile 1:
 ====== Lineare Programme - Aus- und Eingabe - Lösungen ====== ====== Lineare Programme - Aus- und Eingabe - Lösungen ======
  
-<code loesung_3_1.py python>+<code python loesung_3_1.py>
 a=float(input("Zahl1: ")) a=float(input("Zahl1: "))
 b=float(input("Zahl2: ")) b=float(input("Zahl2: "))
Zeile 12: Zeile 12:
 print("Produkt: ",produkt) print("Produkt: ",produkt)
 print("Qotient: ",quotient) print("Qotient: ",quotient)
 +</code>
 +
 +<code python loesung_3_2.py>
 +a=int(input("Zahl1: "))
 +b=int(input("Zahl2: "))
 +summe=a+b
 +differenz=a-b
 +produkt=a*b
 +quotient=a/b
 +quotientganz=a//b
 +rest=a%b
 +print("Summe: ",summe)
 +print("Differenz: ",differenz)
 +print("Produkt: ",produkt)
 +print("Qotient: ",quotient)
 +print("Division mit Rest:",quotientganz,"Rest",rest)
 </code> </code>
python/loesungen/lingrog.1589633877.txt.gz · Zuletzt geändert: 2020/05/16 14:57 von lutz