Follow along with the video below to see how to install our site as a web app on your home screen.
Anmerkung: This feature currently requires accessing the site using the built-in Safari browser.
Ackdeepthroat hat dir doch dein Beispiel geliefert. Wenn das nicht funktioniert, dann machst du irgendwas falsch.
Inzwischen haben drei Leute nach mehr Code gefragt,Aber wie sollen wir den Fehler finden, wenn du nicht einmal den kompletten Code zeigst, der zum Verständnis eurer Lösung hilft?
Habt ihr euch das mal auf einem Blatt Papier überlegt? Das Nachvollziehen hätte ich mir in etwa so vorgestellt:Personlist = temp -> next;
Personlist -> next -> next = temp2 -> next;
Personlist -> next = temp;
Wieso funktioniert das nicht? :/
Anfangszustand
==============
Personlist
|
V
+-------+ +-------+ +-------+
| C | +-->| B | +-->| A |
| next: *--+ | next: *--+ | next: *--> NULL
+-------+ +-------+ +-------+
^ ^
| |
temp temp2
Personlist = temp->next;
========================
Personlist
|
V
+-------+ +-------+ +-------+
| C | +-->| B | +-->| A |
| next: *--+ | next: *--+ | next: *--> NULL
+-------+ +-------+ +-------+
^ ^
| |
temp temp2
Personlist->next->next = temp2->next;
=====================================
Personlist
| +--------+
V V |
+-------+ +-------+ +-------+ |
| C | +-->| B | +-->| A | |
| next: *--+ | next: *--+ | next: *--+
+-------+ +-------+ +-------+
^ ^
| |
temp temp2
Personlist->next = temp;
========================
+-----------------------+
| Personlist |
| | | +--------+
V V | V |
+-------+ +-------+ | +-------+ |
| C | +-->| B | | | A | |
| next: *--+ | next: *--+ | next: *--+
+-------+ +-------+ +-------+
^ ^
| |
temp temp2
+-----------------------+
| Personlist |
| | |
V V |
+-------+ +-------+ | +-------+
| C | | B | | +-->| A |
| next: *--+ | next: *--+ | | next: *--> NULL
+-------+ | +-------+ | +-------+
+----------------+