Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

tripleCut Solitaire Algorithim

 
mike fusc
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
So basically i have a circular linked list.

I have to flip all the cards before 27/28 with the cards after.

For example;

13 10 19 25 8 12 20 18 26 1 9 22 15 3 17 24 2 21 23 7|27 14 5 4 11 16 28|6

circular list becomes

6|27 14 5 4 11 16 28|13 10 19 25 8 12 20 18 26 1 9 22 15 3 17 24 2 21 23 7.

so far i have this, but when the list rebuilds it's missing jokerA to jokerB:

 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic