Suppose we have six constants: 1 through 6.
I would like to have a formula to get all combinations of of them,
I give an example of what I mean:
1 and 2 and 3 and 4 and 5 and 6
1 and 2 and 3 and 4 and 5, but not 6
1 and 2 and 3 and 4, but not 5 and 6
...
2 and 3 and 4 and 5 and 6, but not 1
3 and 4 and 5 and 6, but not 1 and 2
...
1 and 3 and 4 and 5 and 6, but not 2
1 and 4 and 5 and 6, but not 2 and 3
...
...
I Think you've got it.
Lastly, I'd put this in a php script to get the correct combination
if(1 and 2 and 3 and 4 and 5 and 6) { do this }
if(1 and 2 and 3 and 4 and 5) { do that }
For me this is far over my training. Could you please lead me thorugh this.
Thanks.
Our community of experts have been thoroughly vetted for their expertise and industry experience.
The Most Valuable Expert award recognizes technology experts who passionately share their knowledge with the community, demonstrate the core values of this platform, and go the extra mile in all aspects of their contributions. This award is based off of nominations by EE users and experts. Multiple MVEs may be awarded each year.
The Distinguished Expert awards are presented to the top veteran and rookie experts to earn the most points in the top 50 topics.