SHARE
TWEET

Untitled

a guest Sep 18th, 2019 66 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. package percolation;
  2.  
  3. import edu.princeton.cs.algs4.StdIn;
  4. import edu.princeton.cs.algs4.StdOut;
  5. import edu.princeton.cs.algs4.Stopwatch;
  6.  
  7. public class PercolationTester {
  8.     public static void main(String[] args) {
  9.         int N = StdIn.readInt();
  10.         int T = StdIn.readInt();
  11.         Stopwatch stopwatch = new Stopwatch();
  12.         PercolationStats ps = new PercolationStats(N, T);
  13.  
  14.         StdOut.println("Running time: " + stopwatch.elapsedTime() + " seconds.");
  15.         StdOut.println("mean()                  = " + ps.mean());
  16.         StdOut.println("stddev()                = " + ps.stddev());
  17.         StdOut.println("confidenceLow()         = " + ps.confidenceLow());
  18.         StdOut.println("confidenceHigh()        = " + ps.confidenceHigh());
  19.     }
  20.  
  21. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top