Variablenvertauschung
{ x=A and y=B }
x := x+y ;
y := x-y ;
x := x-y
{ x=B and y=A }
Lösung :
NPPV liefert :
Konstruiere ein Programm, das den Inhalt zweier Variablen
vertauscht ohne eine zusätzliche Variable zu benutzen :
Vorherige Folie
Nächste Folie
Zurück zur ersten Folie
Graphik-Version anzeigen