# Friday puzzle post

This week’s Riddler is about a hypothetical gameshow, and knowing when to stop.

You’re on a game show, and you’re asked to sit down at a table covered with sealed envelopes. You are told that each envelope contains a check for an amount of money, each amount different from all the others, but you are given no other information about the distribution of amounts. (As far as you know, the biggest check on the table could be \$1.06 or it could be \$98,765,432,100.00.) You may pick an envelope, open it and read the amount of the check. You can then either keep that check, ending the game, or toss it away permanently and open another envelope. You can then keep that second check or toss it away and open a third envelope. And then you can keep the third check or throw it away and pick a fourth envelope. But that’s it — if you open a fourth envelope, you have to keep that check, no matter how paltry it is.

What strategy should you follow to maximize your chances of getting a nice payday?

# Presentation and data visualization in Excel (Part 1)

Most people I know who analyze data or build models and then present the results do the first part in Excel, but switch over to PowerPoint or something else to make the ‘client-ready’ output. A few years back, I switched to making the majority of my presentations directly in Excel.

This is a topic I’m very interested in, and I’m sure I’ll write more about it later (especially re: pros and cons of making your slides in Excel vs PPT), but for now I just want to share a few examples to give you a flavor of what’s possible in Excel.

# Mapping divisions in the US Senate (part 2)

This is part 2 of my analysis of US Senate voting data. You can find part 1 here.

In part 1, we looked at each senator’s degree of alignment to their party, and how this changed over time. This time, I want to dive a little deeper into comparing senators to each other, separately from their party allegiance.

# Excel challenge solution: Mastermind

A few weeks back, I published an Excel challenge to score, and maybe solve, the game Mastermind in a spreadsheet. Today, I’m going to share some solutions to that challenge. To avoid repeating myself a lot, I’ll assume you’ve read the original challenge already – if you haven’t, I’d suggest you take a look at that first.

[The picture is my own Mastermind board, a particularly excellent gift from my sister-in-law which inspired this challenge.]

# Mapping divisions in the US Senate (part 1)

Unless you’ve been living under a rock for the past several years, you may have heard that partisan divisions are the new normal in US politics, with the exercise of the ‘nuclear option’ to confirm some Presidential appointments, the refusal by the Senate to hold a vote on the President’s nomination for the vacant Supreme Court seat, the brinksmanship around debt-ceiling negotiations (at the time of writing, that link goes to a disambiguation page on the term ‘United States debt-ceiling crisis’, the very existence of which kind of tells you all you need to know…), to name just a few examples.

Of course, it’s easy to think of examples of conflicts that have been in the news lately, and not so easy to get an objective view of long-term changes. So I thought it would be interesting to look at the question with some hard data on how the members of both parties actually vote. Voting data for the US Senate back as far as 1989 is very easily available through senate.gov, and similarly for the House.

# Bar games, advanced maths, and more circular references

So, I promise this blog isn’t going to only feature puzzles and Excel challenges (next ‘real’ post on Friday, if all goes according to plan), but I enjoyed this week’s Riddler enough that I thought I should write something on it.

Consider a hot new bar game. … A marker is placed at zero on [a] number line. Then [a] coin is repeatedly flipped. Every time the coin lands heads, the marker is moved one integer in a positive direction. Every time the coin lands tails, the marker moves one integer in a negative direction. You win if the coin reaches -X first, while your friend wins if the coin reaches +Y first. (Winner keeps the coin.)

How long can you expect to sit, flipping a coin, at the bar?

Here are a few ways you can tackle it (if you’re just an Excel nerd and not a general nerd, you can skip to the last one…):

# Excel challenge: Mastermind

Since the readership for this blog skews heavily toward Excel nerds, I’m going to post an Excel challenge here once in a while. This is the first one, and it comes in three parts, in increasing order of difficulty (I encourage you to have a go even if you don’t think you can do the whole thing).