How many ways can I make six moves on a Rubik's cube?

I am writing a program to solve a Rubik's cube, and would like to know the answer to this question.

There are 12 ways to make one move on a Rubik's cube. How many ways are there to make a sequence of six moves?

From my project's specification: up to six moves may be used to scramble the cube. My job is to write a program that can return the cube to the solved state. I am allowed to use up to 90 moves to solve it. Currently, I can solve the cube, but it takes me over 100 moves (which fails the objective)... so I ask this question to figure out if a brute force method is applicable to this situation.

If the number of ways to make six moves is not overly excessive, I can just make six random moves, then check to see if the cube is solved. Repeat if necessary.

• Are you asking for how many distinct results are there after 6 moves? Or just for how many ways you can make 6 moves, regardless of their uniqueness? – Brandon Carter Nov 9 '10 at 19:07
• I think we should assume we are looking for distinct configurations, since this makes the problem a lot harder/interesting and is more practical for the programming application. – Matt Calhoun Nov 10 '10 at 15:55
• I'm editing the OP to give full details. – dfetter88 Nov 10 '10 at 20:36
• Rather than brute forcing it you could try and implement a solving algorithm from the ones known until now. I'm sure there are some which can get down to less than 50 moves. For example this: ws2.binghamton.edu/fridrich/cube.html Just making random moves until it's done seems it could make lots of unuseful moves, and I guess the 90 limit moves needs some intelligent algorithm. – Beni Bogosel Apr 27 '12 at 9:04