![](master03_background.gif)
FIT100
Flow Chart
Define Artist_Of
Select starting end;
name it alpha
Call beta the slot adjacent to alpha
Is Artist_Of
CD in alpha slot later than Artist_Of CD in beta slot
Is
there a
slot
following the beta
slot?
Is
there a
pair
of slots following alpha?
Interchange CDs in alpha &
beta
![](slide0036_image032.gif)
![](slide0036_image033.gif)
![](slide0036_image034.gif)
![](slide0036_image035.gif)
![](slide0036_image036.gif)
![](slide0036_image037.gif)
Begin calling next slot beta
Advance alpha to next slot & slot after it beta
![](slide0036_image039.gif)
![](slide0036_image040.gif)
1
2
3
4
5
6
N
Y
N
N
Stop
Y
Y