Skip to content

Commit

Permalink
Update Splay Tree
Browse files Browse the repository at this point in the history
  • Loading branch information
Darakuu committed Dec 16, 2023
1 parent 711cec8 commit 44a544f
Show file tree
Hide file tree
Showing 7 changed files with 77 additions and 4 deletions.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
21 changes: 21 additions & 0 deletions content/Attachments/Zig.excalidraw.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
21 changes: 21 additions & 0 deletions content/Attachments/ZigZag.excalidraw.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added content/Attachments/ZigZig.excalidraw.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
21 changes: 21 additions & 0 deletions content/Attachments/ZigZig.excalidraw.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
18 changes: 14 additions & 4 deletions content/Splay Tree.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,14 +28,24 @@ Siano i nodi:
- $g$, nonno;
- $p$, padre o parent;
- $x$, nodo su cui stiamo effettuando l'operazione.


Stiamo effettuando l'operazione Splay su $x$ in tutti i seguenti esempi:
## Zig-Zag

![[ZigZag.excalidraw]]
![[ZigZag.excalidraw.svg]]



Ogni nodo si sposta una posizione a destra seguita da una posizione a sinistra dalla posizione corrente.
## Zig-Zig

![[ZigZig.excalidraw]]
![[ZigZig.excalidraw.svg]]


Altro non è che una doppia operazione zig, definita sotto. Ogni nodo si muove due posizioni a destra dalla sua posizione attuale.
## Zig
Nello Zig il nodo $x$ è sprovvisto di nonno
Nello Zig il nodo $x$ è sprovvisto di nonno. 
Ogni nodo si muove una posizione a destra dalla sua attuale posizione.

![[Zig.excalidraw]]
![[Zig.excalidraw.svg]]

0 comments on commit 44a544f

Please sign in to comment.