I need to create a test base (an array) that follows some rule set.
Example: I have 4 cities: Naples (id=1), London(id=2), Rome (id=3), Milan (id=4).
I need to set some rules like the following: First city must be included in the test array with a probability from 40 to 50%. Second city must be included in the test array with a probability from 20 to 30%. Others cities have the same probability to be included in the array.
Could you help me?
Many Thanks.
Aucun commentaire:
Enregistrer un commentaire