Random Multipool object

Welcome to our brand new Clickteam Community Hub! We hope you will enjoy using the new features, which we will be further expanding in the coming months.

A few features including Passport are unavailable initially whilst we monitor stability of the new platform, we hope to bring these online very soon. Small issues will crop up following the import from our old system, including some message formatting, translation accuracy and other things.

Thank you for your patience whilst we've worked on this and we look forward to more exciting community developments soon!

Clickteam.
  • I am having a problem getting the right generated output based on a limited pool.

    the limit is from 1 to 30. but the object generats 0 insted of 1 in the list of the 30 generated numbers.

    With Best Regards

    What matters is not to add years to your life but to add life to your years.
    Give yourself some time.

  • Hi Mokhtar,

    Please login to see this link. shows that the limits of the pool are from 1 to 30.
    but the number 0 is always generated. It is meant to generate numbers from 1 to 30.

    With Regards

    What matters is not to add years to your life but to add life to your years.
    Give yourself some time.

  • Isn't it 0-based index?

    In standard random function you've got something like random(2) will random 2 numbers but first one by default is 0 second 1, so if you will do random(30) it will go from 0 up to 29, but if you want to have from 1 to 30 you just need to add +1 -> (random(30)+1)

    End is near.

  • No, it's not 0-based if you specify the limits explicitly. You should get 1 to 30. However, the mistake you're using is that you're combining fast generate with the normal generate number. So you have one extra 0 at the beginning. Instead, use the normal generate action, and on number generated generate the next one.

    -Mokhtar M. Khorshid

  • Quote from Mokhtar

    No, it's not 0-based if you specify the limits explicitly. You should get 1 to 30. However, the mistake you're using is that you're combining fast generate with the normal generate number. So you have one extra 0 at the beginning. Instead, use the normal generate action, and on number generated generate the next one.


    I am sorry I was not sure if the same answer would apply to my problem too. To give some more details, I have tried using the loop operation and the iterated numbers are generated as the string of the loop index which I could not find how to randomize. I have however managed to use the manual seed and using the negated pool “ ” empty to fill the list with 30 random numbers. But this is extremely slow.


    Regards

    What matters is not to add years to your life but to add life to your years.
    Give yourself some time.

  • That answer was specifically for your problem. You basically just use the same event you're using now, but you would put in it the action to generate a new number as well after using the current one. This will cause the event to trigger again once the new number is generated (no need for an explicit loop).

    -Mokhtar M. Khorshid

  • Hi Mokhtar,

    thank you! I was confused by "fast generate with the normal generate number". The problem was resolved using the Last Generated Number instead of Fast Generate Number.
    and generating a number agin as you mentioned.

    Thank you a gain.

    Best Regards

    What matters is not to add years to your life but to add life to your years.
    Give yourself some time.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!