asd
This commit is contained in:
+14
-8
@@ -1,12 +1,18 @@
|
||||
from knoten import Knoten
|
||||
|
||||
k1=Knoten(1)
|
||||
print(k1.data)
|
||||
k2=Knoten(2)
|
||||
print(k2.data)
|
||||
class Liste:
|
||||
def __init__(self):
|
||||
self.head = None
|
||||
|
||||
k1.next=k2
|
||||
print("--")
|
||||
def ausgebenListe(self):
|
||||
|
||||
print(k1.next.data)
|
||||
print(k2.data)
|
||||
aktueller_knoten = self.head
|
||||
|
||||
while aktueller_knoten is not None:
|
||||
|
||||
print(aktueller_knoten.data)
|
||||
|
||||
aktueller_knoten = aktueller_knoten.next
|
||||
|
||||
def append(self,data):
|
||||
h=1
|
||||
Reference in New Issue
Block a user