Serving the Quantitative Finance Community

 
User avatar
katastrofa
Topic Author
Posts: 7440
Joined: August 16th, 2007, 5:36 am
Location: Alpha Centauri

Snowflake version of Josephus problem

February 3rd, 2022, 11:10 am

You have a deck of 52 cards. You take a top card and alternately put it aside and on the bottom. Which card (numbered from 1 to 52) will remain?
 
User avatar
trackstar
Posts: 3420
Joined: January 1st, 1970, 12:00 am

Re: Snowflake version of Josephus problem

February 3rd, 2022, 2:34 pm

I looked the Josephus Problem up and see what you mean by "snowflake version" - haha! : ) We can have a Russian Roulette problem next! 

Since it might be considered "cheating" to Google a brainteaser and then offer a solution, I will wait and see if any one else will solve it today.
snowflake.jpg
 
User avatar
Marsden
Posts: 788
Joined: August 20th, 2001, 5:42 pm
Location: Maryland

Re: Snowflake version of Josephus problem

February 3rd, 2022, 7:12 pm

Hm.

First pass: all of the odd cards are set aside, if I understand the process correctly.

Divide by two; now we have cards numbered 1 to 26. Again all of the odd cards are set aside.

Divide by two again; now we have cards numbered 1 to 13. Again all of the odd cards are set aside.

Divide by two again; now we have cards numbered 1 to 6. This time all of the even cards are set aside.

Now we have cards renumbered 1, 3, and 5. 1 is sent to bottom; 3 is discarded; 5 is sent to bottom; 1 is discarded; 5 is only one left.

5 was halved three times, so it was originally card 40.

Is that right?
 
User avatar
katastrofa
Topic Author
Posts: 7440
Joined: August 16th, 2007, 5:36 am
Location: Alpha Centauri

Re: Snowflake version of Josephus problem

February 3rd, 2022, 7:51 pm

Yes! I mixed up the puzzle a bit (in the original puzzle you stabbed your neighbour and passed the sword to the second neighbour so that he can stab his neighbour...). It can be generalised to n cards and putting aside every k-th card.
 
User avatar
bearish
Posts: 5186
Joined: February 3rd, 2011, 2:19 pm

Re: Snowflake version of Josephus problem

February 3rd, 2022, 7:56 pm

I also got to 40, after briefly bemoaning the fact that there aren’t like 64 cards in a deck. But 40 is the 13th card when counting from the bottom.
 
User avatar
Marsden
Posts: 788
Joined: August 20th, 2001, 5:42 pm
Location: Maryland

Re: Snowflake version of Josephus problem

February 4th, 2022, 12:20 am

There was a very elegant card puzzle posted here years ago, and I suspect it would be more difficult to find than to just try to rephrase here, so:

You and an assistant are to perform a mentalist trick with a deck of cards. The way it works is that a third party is to pick any five cards out of a 52-card deck and hand those five cards to you. After looking at the five cards, you choose one of them and remove it from the set: this will be the card your assistant will have to guess. Then you arrange the remaining four cards however you like and pass them to your assistant, who based on those cards and their order has to figure out what the fifth card is.

So the puzzle is to figure out a system for picking the card to be guessed out of the five you are given, and then arranging the remaining four so that your assistant will be able to determine the fifth card without fail.
 
User avatar
trackstar
Posts: 3420
Joined: January 1st, 1970, 12:00 am

Re: Snowflake version of Josephus problem

February 4th, 2022, 12:39 am

There was a very elegant card puzzle posted here years ago, and I suspect it would be more difficult to find than to just try to rephrase here, so:

You and an assistant are to perform a mentalist trick with a deck of cards. The way it works is that a third party is to pick any five cards out of a 52-card deck and hand those five cards to you. After looking at the five cards, you choose one of them and remove it from the set: this will be the card your assistant will have to guess. Then you arrange the remaining four cards however you like and pass them to your assistant, who based on those cards and their order has to figure out what the fifth card is.

So the puzzle is to figure out a system for picking the card to be guessed out of the five you are given, and then arranging the remaining four so that your assistant will be able to determine the fifth card without fail.
Had a quick look around and here it is: Tough card/math teaser circa 2004 

January 5th, 2004, 2:13 pm by Mike Bell

You have a deck of fair/unaltered cards. You are working with a friend who is in another room. You get someone to pick 5 cards. Any 5 cards from the deck of 52. You take these 5 cards, you pick one card to be a secret one and you arrange the other 4 in any way you want and you put them up on the table, face up. Your friend comes along and he guesses correctly the 5th, hidden, card. This is a "trick" about how to encode the cards.This, folks, separates men from the boys.
 
User avatar
Paul
Posts: 6604
Joined: July 20th, 2001, 3:28 pm

Re: Snowflake version of Josephus problem

February 4th, 2022, 12:53 am

This is a "trick" about how to encode the cards.This, folks, separates men from the boys.
I've got one. You have to sort out the virgins from the non virgins with just one question. What is that question?

Answer: "You have a deck of fair/unaltered cards..."
 
User avatar
katastrofa
Topic Author
Posts: 7440
Joined: August 16th, 2007, 5:36 am
Location: Alpha Centauri

Re: Snowflake version of Josephus problem

February 4th, 2022, 9:34 pm

Re the virgin cards, if I can arrange the four cards any way I like (but facing up from what I understand), I can e.g. use one card to indicate the suit with rotations by half a pi (factor group to be precise - but not necessarily correct), and in the same way encode the rank in quaternary system with two of the remaining cards, and give the last card to the cats to play.
 
User avatar
Marsden
Posts: 788
Joined: August 20th, 2001, 5:42 pm
Location: Maryland

Re: Snowflake version of Josephus problem

February 5th, 2022, 2:42 pm

lol

Good answer!

I think the "arrange the other 4 in any way you want" should be "put the other 4 in any order, all face up and with the same orientation, that you want."

There is a clever card trick -- again using two people to impress a third -- where ten cards, at least one of them a ten of any suit, are laid out on a table with the same arrangement as the suit markers on a ten card. Then the mark third person picks any of the ten cards, or even multiple cards, pointing them out to one of the two cons mentalists out of sight of the other. Then the con mentalist who knows the card(s) chosen makes a bunch of apparently random touches of the cards on the table, and the other con mentalist guesses the chosen card(s).

And the trick is that the ten card on the table is used as a map of the other cards, so it will be touched on the suit marker corresponding to the chosen card.