public class Histogram2 { static int numBins = 10; public static void main (String[] argv) { int numSamples = 10000; int n = 5; histogramForUprime (n, numSamples); //histogramForVprime (n, numSamples); //histogramForWprime (n, numSamples); } static double computeUprime (int n) { // INSERT YOUR CODE HERE do generate a random // number DIFFERENT from RandTool.uniform(). // Call RandTool.uniform() and do something to it. } static double computeVprime (int n) { // INSERT YOUR CODE HERE. } static double computeWprime (int n) { // INSERT YOUR CODE HERE. Remember to subtract // off whatever Vn appears to be converging to (not 0.5). } // You don't need to modify any code below this. It's more or less // the same as in Histogram.java static void histogramForUprime (int n, int numSamples) { // Generate the data set double[] data = new double [numSamples]; for (int k=0; k max) max = data[i]; } // Interval size. double interval = (max-min) / numBins; // Now count. for (int i=0; i= 0) && (whichBin < numBins) ) { bins[whichBin] ++; } } // Print histogram. for (int b=0; b