I want to give points on random number

user gives two numbers in the first input user enters 5 and in second output user enters 10
user give total points = like 100 ;

we have two number
var A = 5;
var B = 10;
var totalpoints = 100;

now firstly, I want to generate random numbers like 5, 8 , 9 , 6 , 7,10
and secondly give a random point to the random numbers like:

5,8 = 10 points,
5,6,7,8,9,10 = 10points,
5,6 = 50 points
5,10 = 30, 30 points,
7,8,9, = 90points,
6,10 = 40points,

i want that type of output in which random number and random points but that total points for each number is equal to user that given by user ,

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.