Treesort
Upcoming SlideShare
Loading in...5
×
 

Treesort

on

  • 1,104 views

Slides for a small Presentation of a simple Demo written Qt and C++ in 2001. Later i ported it to Java. I did not use C++ Template Library or Java Collection but coded my dynamic Data Structure for ...

Slides for a small Presentation of a simple Demo written Qt and C++ in 2001. Later i ported it to Java. I did not use C++ Template Library or Java Collection but coded my dynamic Data Structure for myself and sorted it with the ancient Treesort Algorithm I had learned at University i an Lecture for funtional Programming with ML.

Statistics

Views

Total Views
1,104
Views on SlideShare
1,104
Embed Views
0

Actions

Likes
0
Downloads
10
Comments
0

0 Embeds 0

No embeds

Accessibility

Categories

Upload Details

Uploaded via as Microsoft PowerPoint

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

    Treesort Treesort Presentation Transcript

    • Treesort Thomas Wöhlke
    • Treesort Problem: Sortieren einer Liste - Liste hat unbekannte Länge - Liste ist kein Array Beispiel: Doppelt Zeiger-verkettete Liste Lösung: Sortieren mit Treesort
    • Treesort Algorithmus: Phase 1: Aufbau eines Binär-Baumes aus den Elementen der Liste. Phase 2: Traversieren (inorder) des Baumes und dabei Neu-Aufbau der Liste. => Liste ist sortiert.
    • Phase 1: Binär-Baum aufbauen D C F A G X V K
    • Baum aufbauen D C F A G X V K C
    • Baum aufbauen D C F A G X V K C F
    • Baum aufbauen D C F A G X V K C F A
    • Baum aufbauen D C F A G X V K C F A G
    • Baum aufbauen D C F A G X V K C F A G D
    • Baum aufbauen D C F A G X V K C F A G D X
    • Baum aufbauen D C F A G X V K C F A G D X V
    • Baum aufbauen D C F A G X V K C F A G D X V K
    • Phase 2: Traversieren A C F A G D X V K 1
    • Phase 2: Traversieren C A C F A G D X V K 1 2
    • Phase 2: Traversieren D C A C F A G D X V K 1 3 2
    • Phase 2: Traversieren D C F A C F A G D X V K 1 3 4 2
    • Phase 2: Traversieren D C F A G C F A G D X V K 1 3 4 2 5
    • Phase 2: Traversieren D C F A G K C F A G D X V K 1 3 4 2 6 5
    • Phase 2: Traversieren D C F A G V K C F A G D X V K 1 3 4 2 7 6 5
    • Phase 2: Traversieren D C F A G X V K C F A G D X V K 1 3 4 2 7 6 5 8
    • Treesort Thomas Wöhlke