Lottery ticket number generator

I need a help. pls, let me know how to make a process or generator for lottery ticket number.
I used random = random().Next(1, 50) and inserted random numbers into collection(Add To Collection activity), but couldn’t check overwarped number.
Need your help.

Hi @gregoryc_103

What u mean by overwrapped number

Lottery teicket have six different numbers. I mean same numbers.

Oh u mean numbers like this 666666 like this type ?

number’s range is 1 to 50.
ex) 1 ticket - 1, 5, 7, 30, 33, 44(randomly)
So i used a list type(Int32 or integer)

Hi,

How about the following?

Sample20201110-1.zip (2.6 KB)

Regards,

Check if generated number is already in your collection
ex.
if yourCollection.Contains(random)
then Make another number
else Add to Collection

Hi, thank you for your help.
I have questions more. There are some conditions for a lottery ticket number.

  1. range: number’s count is 6. (number.Count < 7) ex) (1, 4, 5, 30, 33, 49)
  2. need to sort out duplicated numbers.

Hi, thank you for your help.
I have questions more. There are some conditions for a lottery ticket number.

  1. range: number’s count is 6. (number.Count < 7) ex) (1, 4, 5, 30, 33, 49)
  2. need to sort out duplicated numbers.