Came across an interesting article today via HackerNews by Ben Joffe, who figured out how to stack a deck of cards so that regardless of how its cut, you are dealt winning cards. Seems like he figured it out by iterating over possible deck combinations until his algorithm found one that met the requirements. Pretty cool.
I do not condone cheating in poker, it is immoral, dangerous and often illegal, but out of curiosity I was wondering if it is possible to stack a deck so that no matter which way it is cut, the winning hand is always dealt to the dealer. This would be fun to use as a magic trick, to be able to consistently predict the winning hand.