Jump to content



0

Math question: 3 x 8 = 24?


5 replies to this topic

#1 Random Terrain OFFLINE  

Random Terrain

    Visual batari Basic User

  • 20,923 posts
  • Controlled Randomness
    Replay Value
    Nonlinear
  • Location:North Carolina (USA)

Posted Sun Aug 21, 2011 4:22 AM

If you divide the screen into three sections and have your program randomly select one of eight pieces for each section, how do you figure out how many combinations that is?

Is it as simple as 3 x 8 = 24? Or would there be more than 24 combinations?



Thanks.

#2 RevEng ONLINE  

RevEng

    River Patroller

  • 2,011 posts
  • bit shoveler
  • Location:Canada

Posted Sun Aug 21, 2011 7:35 AM

To calculate the total number of combinations you multiply the total number of states of each factor together.

So in your case its 8x8x8=512.

Much better than 24! :)

#3 Random Terrain OFFLINE  

Random Terrain

    Visual batari Basic User

  • 20,923 posts
  • Controlled Randomness
    Replay Value
    Nonlinear
  • Location:North Carolina (USA)

Posted Sun Aug 21, 2011 8:34 AM

View PostRevEng, on Sun Aug 21, 2011 7:35 AM, said:

To calculate the total number of combinations you multiply the total number of states of each factor together.

So in your case its 8x8x8=512.

Much better than 24! :)
I knew there had to be more to it! Thanks!

I'm almost done with a 16 x 16 x 16 version, so I guess that's 4,096. :-o

#4 RevEng ONLINE  

RevEng

    River Patroller

  • 2,011 posts
  • bit shoveler
  • Location:Canada

Posted Sun Aug 21, 2011 8:56 AM

No problem!

View PostRandom Terrain, on Sun Aug 21, 2011 8:34 AM, said:

I'm almost done with a 16 x 16 x 16 version, so I guess that's 4,096. :-o
Very nice! :)

#5 SpiceWare OFFLINE  

SpiceWare

    Quadrunner

  • 5,990 posts
  • Medieval Mayhem
  • Location:Planet Houston

Posted Sun Aug 21, 2011 12:13 PM

Can the pieces only be used once, or could the same piece show up in all 3 sections? If only once then it's 8 x 7 x 6.

#6 Random Terrain OFFLINE  

Random Terrain

    Visual batari Basic User

  • 20,923 posts
  • Controlled Randomness
    Replay Value
    Nonlinear
  • Location:North Carolina (USA)

Posted Sun Aug 21, 2011 12:25 PM

View PostSpiceWare, on Sun Aug 21, 2011 12:13 PM, said:

Can the pieces only be used once, or could the same piece show up in all 3 sections? If only once then it's 8 x 7 x 6.
Each section has 16 pieces that are different from the other sections and they are chosen at random:

http://www.atariage....maze-test-2011/

The only limitation is that I added a little bit of memory so no section can display a piece twice in a row. For example, if piece 6 was the last middle piece used, piece 6 can't be displayed this time.

Edited by Random Terrain, Sun Aug 21, 2011 12:38 PM.





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users