How many combos?

Discuss anything interesting but not remotely Countdown-related here.

Moderator: Jon O'Neill

Post Reply
User avatar
Adam Dexter
Enthusiast
Posts: 325
Joined: Fri Jan 23, 2009 4:41 pm
Location: Kidderminster

How many combos?

Post by Adam Dexter » Thu Nov 22, 2018 2:16 pm

Hi

Looking to build a massive Multiple IF formula on Excel.

How many combos of days of the week are there, allowing for days to be either there or not?

E.g.

Week could be MTW, MTFS, SMWFS, SMTWTFS or anywhere between
ADAM DEXTER: MAXED DATER
We're off to button moon :)

Thomas Cappleman
Acolyte
Posts: 189
Joined: Fri Nov 07, 2008 9:42 pm

Re: How many combos?

Post by Thomas Cappleman » Thu Nov 22, 2018 2:20 pm

2^7=128 (each day can either be in the set or not). Or 127 if you discount the empty list.

User avatar
Adam Dexter
Enthusiast
Posts: 325
Joined: Fri Jan 23, 2009 4:41 pm
Location: Kidderminster

Re: How many combos?

Post by Adam Dexter » Thu Nov 22, 2018 2:28 pm

Thanks! Looks like my multiple if formula won't work as it's max 64.

This is what I'm looking at btw

https://exceljet.net/puzzle/formula-cha ... ys-of-week
ADAM DEXTER: MAXED DATER
We're off to button moon :)

Thomas Cappleman
Acolyte
Posts: 189
Joined: Fri Nov 07, 2008 9:42 pm

Re: How many combos?

Post by Thomas Cappleman » Thu Nov 22, 2018 2:47 pm

Yeah, you definitely don't want to do that by working out each combination individually. Doing 7 individual IF tests then combining the results as a string would be ideal, however you do that in Excel.

User avatar
JimBentley
Legend
Posts: 2722
Joined: Fri Jan 11, 2008 6:39 pm
Location: Redcar, UK
Contact:

Re: How many combos?

Post by JimBentley » Thu Nov 22, 2018 3:10 pm

This is quite an interesting problem if you're looking to do it within a single cell. I like trying to do this sort of thing for the sake of neatness, but often it's just easier and quicker to take another route. Like Tom said, seven individual IF statements in separate cells, combined into an eighth would be far better (you can hide the seven interim steps and just show the result). However, I'd just write a small macro to do it.

Thomas Cappleman
Acolyte
Posts: 189
Joined: Fri Nov 07, 2008 9:42 pm

Re: How many combos?

Post by Thomas Cappleman » Thu Nov 22, 2018 3:17 pm

There's probably even a way to do the seven IF tests and combine the results in a single cell (essentially whatever you'd put in the 7 separate cells, combined into one formula).

User avatar
Adam Dexter
Enthusiast
Posts: 325
Joined: Fri Jan 23, 2009 4:41 pm
Location: Kidderminster

Re: How many combos?

Post by Adam Dexter » Thu Nov 22, 2018 3:52 pm

Did it woohoo.

How do I upload a pic?
ADAM DEXTER: MAXED DATER
We're off to button moon :)

User avatar
Adam Dexter
Enthusiast
Posts: 325
Joined: Fri Jan 23, 2009 4:41 pm
Location: Kidderminster

Re: How many combos?

Post by Adam Dexter » Thu Nov 22, 2018 3:55 pm

Image
ADAM DEXTER: MAXED DATER
We're off to button moon :)

User avatar
JimBentley
Legend
Posts: 2722
Joined: Fri Jan 11, 2008 6:39 pm
Location: Redcar, UK
Contact:

Re: How many combos?

Post by JimBentley » Thu Nov 22, 2018 4:01 pm

Adam Dexter wrote:
Thu Nov 22, 2018 3:52 pm
Did it woohoo.

How do I upload a pic?
This board doesn't do image hosting, so you'll need to upload it somewhere else and then link to it. I've used Imgur in the past but they've somehow managed to break their direct linking facility recently and it doesn't work anymore, but there are plenty of other image hosts available which will give a direct link to the image, which you then just post as [ img ]image URL[ /img ] (ignore the spaces, that's just to stop the board thinking I've posted an actual image there). But if you want you can just send it to me at fahnnx@googlemail.com and I'll stick it on my site because I'm nice like that.

Post Reply

Who is online

Users browsing this forum: No registered users and 6 guests