# Combinatorics and Pampers

I’m a mom of a toddler and a newborn, so my house goes through a lot of diapers. We’ve been using Pampers almost exclusively since my son was born in 2010. Pampers offers a program called “Pampers Rewards” where you can enter codes found on Pampers products to their website, and redeem for cool stuff. (Let’s agree to ignore all issues about the effects of disposable diapers on the world ecology, or on family size and the exponentially growing population of humans on our planet, or the obvious questions about why Pampers is trading me stuff for lots of data about how often my kids pee.)

The coding scheme that Pampers uses has bothered me for a while. Each Pampers item comes with an alphanumeric 15-digit code, something like “T9PDXPKKGA3M4GK”. Given that for each character we have 36 possibilities, and the codes are 15 characters long, there are a whopping 3615 such codes. This is about 2.2×1023. That’s a lot of possible codes! How many? If every single one of the seven billion people (7×109)  on the planet used Pampers, there would be enough possible codes for each person to have one billion codes just for themselves — and then there would still be some left over. While my kids use a lot of diapers, I surely hope we don’t end up needing a billion boxes of Pampers for each of them.

Why does Pampers do this? I am not sure. Instead of an alphanumeric code, why not just use an alphabetical sequence of length 15? This would mean “only” 2615, or a little shy of 1.7×1021. In this case, there would still be more than a billion codes available for each one of the seven billion of us.

It’s in Pampers’s interest to make sure only a small percentage of all possible codes are actually connected with a particular product; this prevents fraud on their Rewards program. If I were going to design codes, I’d want to make sure that of all possible codes, maybe only one in a million actually worked. I’ll even be very cautious and allow only one in ten billion (1 in 1010) to actually appear on a product. What is one ten-billionth of 3615? It’s about 2.2×1013. This would still leave Pampers with over ten trillion (1013) usable codes. Surely they could find a more efficient coding scheme.

Apart from efficiency, I’d really love it if Pampers would just print the associated QR code along with the actual 15-digits. Having to type in multiple 15-digit codes on my Pampers iPhone app, while chasing a toddler, nursing a newborn, and typing a blog post, is really quite taxing!