MCPcopy Index your code
hub / github.com/apache/groovy / main

Method main

benchmark/bench/heapsort.java:13–25  ·  view source on GitHub ↗
(String args[])

Source from the content-addressed store, hash-verified

11 public static final long IC = 29573;
12
13 public static void main(String args[]) {
14 int N = Integer.parseInt(args[0]);
15 NumberFormat nf = NumberFormat.getInstance();
16 nf.setMaximumFractionDigits(10);
17 nf.setMinimumFractionDigits(10);
18 nf.setGroupingUsed(false);
19 double []ary = (double[])Array.newInstance(double.class, N+1);
20 for (int i=1; i<=N; i++) {
21 ary[i] = gen_random(1);
22 }
23 heapsort(N, ary);
24 System.out.print(nf.format(ary[N]) + "\n");
25 }
26
27 public static long last = 42;
28 public static double gen_random(double max) {

Callers

nothing calls this directly

Calls 7

gen_randomMethod · 0.95
heapsortMethod · 0.95
parseIntMethod · 0.80
getInstanceMethod · 0.65
newInstanceMethod · 0.65
printMethod · 0.45
formatMethod · 0.45

Tested by

no test coverage detected