Santa’s elves need to line up nine reindeer — Rudolph, Prancer, Cupid, Comet, Blitzen, Donder, Vixen, Dancer, and Dasher — into a single order to pull the sleigh, following a set of “behind” / “in front of” constraints such as:
- Comet is behind Rudolph, Prancer, and Cupid
- Blitzen is behind Cupid, and in front of Donder, Vixen, and Dancer
- Cupid is in front of Comet, Blitzen, and Vixen, and also in front of Rudolph and Dancer
- Donder is behind Vixen, Dasher, and Prancer, and also behind Comet and Cupid
- Rudolph is behind Prancer, and in front of Donder, Dancer, and Dasher
- Vixen is in front of Dancer and Comet, and behind Rudolph, Prancer, and Dasher
- Dancer is behind Donder, Rudolph, and Blitzen
- Prancer is in front of Cupid, Donder, and Blitzen
- Dasher is behind Prancer, and in front of Vixen, Dancer, and Blitzen
Find a total ordering of all nine reindeer that satisfies every constraint above.
Send your solutions to DecisionManagementCommunity@gmail.com, or open a pull request to add yours here.