Advertisement

Two Arrays

Started by August 13, 2013 10:08 AM
0 comments, last by WitchLord 11 years, 3 months ago

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'
                };

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

This topic is closed to new replies.

Advertisement