Jump to content

  • Log In with Google      Sign In   
  • Create Account


- - - - -

Two Arrays


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
1 reply to this topic

#1 povilaslt2   Members   -  Reputation: 201

Like
0Likes
Like

Posted 13 August 2013 - 04:08 AM

Hey there, i have problem. I have 2 arrays and i want to get all possible combinations with these two arrays. For example: mUtrucu6. Can you help me?

                char[] charactersToTest =
                {
                    'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j',
                    'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't',
                    'u', 'v', 'w', 'x', 'y', 'z','A','B','C','D','E',
                    'F','G','H','I','J','K','L','M','N','O','P','Q','R',
                    'S','T','U','V','W','X','Y','Z',
                };
                char[] charactersToTest =
                {
                    '1','2','3','4','5','6','7','8','9','0'
                };

Edited by povilaslt2, 13 August 2013 - 04:08 AM.


Sponsor:

#2 Andreas Jonsson   Moderators   -  Reputation: 3291

Like
0Likes
Like

Posted 13 August 2013 - 11:43 AM

All possible combinations would give an infinite set of strings, unless you put some restrictions on the valid combinations.

 

I would recommend looking up algorithms on computing possible permutations on a given set of data.

 

What do you need this for?


AngelCode.com - game development and more - Reference DB - game developer references
AngelScript - free scripting library - BMFont - free bitmap font generator - Tower - free puzzle game




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS