We help IT Professionals succeed at work.
Get Started

How could I generate every possible question/answer combination?

432 Views
1 Endorsement
Last Modified: 2013-11-22
I need to generate a list showing every possible combination of answers to several questions.
Each row in this list should be another possible combination of answers.  

For example, there might be two questions (question 1 & question 2), question 1 has two possible responses (a or b), question 2 has three possible response (a, b, or c). Below is the kind of list I need showing each possible combination on a separate row:

1a, 2a
1a, 2b
1b, 2a
1b, 2b
1b, 2c

In Excel or Access or some other common tool, I'd like to specify the number of questions & number of answers for each question & get a list or table like the one above.  Is this possible using VBA or something else available via MS Office or on the web?
Comment
Watch Question
Top Expert 2013
Commented:
This problem has been solved!
Unlock 1 Answer and 29 Comments.
See Answer
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE