CS 112 Project 6: Conga Trace

A conga line

Simulation Trace

When run, the CongaLine simulation should behave like the trace shown below:

Ann and Bob have started a Conga Line!

 Ann=>Bob

Conga, Conga, Con-GA!  Conga, Conga, Con-GA!

Please enter:
 1 to join the Conga line at the end
 2 to join the Conga line after a particular person
 3 to join the Conga line before a particular person
 4 to quit
--> 1

What is your name? Chris

 Ann=>Bob=>Chris

Conga, Conga, Con-GA!  Conga, Conga, Con-GA!

Please enter:
 1 to join the Conga line at the end
 2 to join the Conga line after a particular person
 3 to join the Conga line before a particular person
 4 to quit
--> 2

What is your name? Don
Who do you want to follow? Ann

 Ann=>Don=>Bob=>Chris

Conga, Conga, Con-GA!  Conga, Conga, Con-GA!

Please enter:
 1 to join the Conga line at the end
 2 to join the Conga line after a particular person
 3 to join the Conga line before a particular person
 4 to quit
--> 2

What is your name? Eve
Who do you want to follow? Bob

 Ann=>Don=>Bob=>Eve=>Chris

Conga, Conga, Con-GA!  Conga, Conga, Con-GA!

Please enter:
 1 to join the Conga line at the end
 2 to join the Conga line after a particular person
 3 to join the Conga line before a particular person
 4 to quit
--> 2

What is your name? Fred
Who do you want to follow? Chris

 Ann=>Don=>Bob=>Eve=>Chris=>Fred

Conga, Conga, Con-GA!  Conga, Conga, Con-GA!

Please enter:
 1 to join the Conga line at the end
 2 to join the Conga line after a particular person
 3 to join the Conga line before a particular person
 4 to quit
--> 3

What is your name? Gwen
Who do you want to precede? Ann

 Gwen=>Ann=>Don=>Bob=>Eve=>Chris=>Fred

Conga, Conga, Con-GA!  Conga, Conga, Con-GA!

Please enter:
 1 to join the Conga line at the end
 2 to join the Conga line after a particular person
 3 to join the Conga line before a particular person
 4 to quit
--> 3

What is your name? Hal9000
Who do you want to precede? Eve

 Gwen=>Ann=>Don=>Bob=>Hal9000=>Eve=>Chris=>Fred

Conga, Conga, Con-GA!  Conga, Conga, Con-GA!

Please enter:
 1 to join the Conga line at the end
 2 to join the Conga line after a particular person
 3 to join the Conga line before a particular person
 4 to quit
--> 3

What is your name? Ivy
Who do you want to precede? Fred

 Gwen=>Ann=>Don=>Bob=>Hal9000=>Eve=>Chris=>Ivy=>Fred

Conga, Conga, Con-GA!  Conga, Conga, Con-GA!

Please enter:
 1 to join the Conga line at the end
 2 to join the Conga line after a particular person
 3 to join the Conga line before a particular person
 4 to quit
--> 2

What is your name? Joe
Who do you want to follow? Bilbo

*** Bilbo is not dancing!


 Gwen=>Ann=>Don=>Bob=>Hal9000=>Eve=>Chris=>Ivy=>Fred

Conga, Conga, Con-GA!  Conga, Conga, Con-GA!

Please enter:
 1 to join the Conga line at the end
 2 to join the Conga line after a particular person
 3 to join the Conga line before a particular person
 4 to quit
--> 3

What is your name? Jon
Who do you want to precede? Frodo

*** Frodo is not dancing!

 
 Gwen=>Ann=>Don=>Bob=>Hal9000=>Eve=>Chris=>Ivy=>Fred

Conga, Conga, Con-GA!  Conga, Conga, Con-GA!

Please enter:
 1 to join the Conga line at the end
 2 to join the Conga line after a particular person
 3 to join the Conga line before a particular person
 4 to quit
--> 0

*** 0 is not a valid choice!


 Gwen=>Ann=>Don=>Bob=>Hal9000=>Eve=>Chris=>Ivy=>Fred

Conga, Conga, Con-GA!  Conga, Conga, Con-GA!

Please enter:
 1 to join the Conga line at the end
 2 to join the Conga line after a particular person
 3 to join the Conga line before a particular person
 4 to quit
--> 5

*** 5 is not a valid choice!


 Gwen=>Ann=>Don=>Bob=>Hal9000=>Eve=>Chris=>Ivy=>Fred

Conga, Conga, Con-GA!  Conga, Conga, Con-GA!

Please enter:
 1 to join the Conga line at the end
 2 to join the Conga line after a particular person
 3 to join the Conga line before a particular person
 4 to quit
--> 4

CS > 112 > Projects > 06 Conga Trace


This page maintained by Joel Adams.