The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
How to get all possible combinations?
I want to try something different with php, and by this I want to apply it to a word problem.
How would I go about getting the possible combinations of 1,2,3,4,5 in possible orders, here are some possible orders, and examples of wrong orders. 2,3,4,5,1 = right 5,4,3,2,1 = right 1,3,2,5,4 = wrong 4,5,6,1,2 = right It has to follow in sequence. How would i go about getting php to output all possible combinations in that way, or if not all possible combinations in total without the right or wrong? I know for a fact there are some 120 possible combinations, of which only 70 some are able to follow in sequence. Thanks for your help, I want to test this to get me ready for programing in college. |
#2
|
|||
|
|||
*bump*
after few days irate: |
#3
|
||||
|
||||
try php.net because i can't think of anything that'd do this OR if your in school, go to your math teacher and ask them if there's a way to do this then do that in php
|
#4
|
|||
|
|||
Its for college TEE Web Programming
|
#5
|
|||
|
|||
Writing something now.
|
#6
|
|||
|
|||
Enjoy my numerous cheap hacks and crazy boolean mixes:
|
#7
|
|||
|
|||
Hey thats cool,
Quote:
|
#8
|
|||
|
|||
I don't know. Right now all it does is verify existing combinations.
|
#9
|
||||
|
||||
You have too much time on your hands filburt. That is one nice script
- miSt |
#10
|
|||
|
|||
Before I noticed that it had to check forwards and backwards, I had it actually highlighting the point in the sequence where it went wrong.
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|