generation of random numbers in java
<p>I want to create 30 tables which consists of the following fields. For example,</p>

<pre>
Service_ID   Service_Type     consumer_feedback 
  75           Computing        1                 
  35           Printer          0                 
  33           Printer         -1                
3 rows in set (0.00 sec)
</pre>

<pre>
mysql> select * from consumer2;
Service_ID   Service_Type     consumer_feedback   
  42           data             0
  75           computing        0
</pre>

<pre>
mysql> select * from consumer3;
Service_ID   Service_Type     consumer_feedback 
  43           data            -1
  41           data             1 
  72           computing       -1
</pre>

<p>As you can infer from the above tables, I am getting the feedback values. I have generated these <code>consumer_feedback</code> values, <code>Service_ID</code>, <code>Service_Type</code> using the concept of random numbers. I have used the function:</p>

<pre><code>int min1=31;//printer
int max1=35;//the values are generated if the Service_Type is printer.
int provider1 = (int) (Math.random() * (max1 - min1 + 1) ) + min1;
int min2=41;//data
int max2 =45
int provider2 = (int) (Math.random() * (max2 - min2 + 1) ) + min2;
int min3=71;//computing
int max3=75;
int provider3 = (int) (Math.random() * (max3 - min3 + 1) ) + min3;        
int min5 = -1;//feedback values
int max5 =1;
int feedback = (int) (Math.random() * (max5 - min5 + 1) ) + min5;
</code></pre>

<p>I need the <code>Service_Types</code> to be distributed uniformly in all the 30 tables. Similarly I need feedback value of 1 to be generated many times other than 0 and -1.</p>
