From 2af84c86ed22ee28a49d985e6031e8676120893f Mon Sep 17 00:00:00 2001 From: Roan Hofland Date: Thu, 27 Aug 2020 00:49:42 +0200 Subject: [PATCH] Remove redundant type casts --- KeysPerSecond/src/me/roan/kps/Main.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/KeysPerSecond/src/me/roan/kps/Main.java b/KeysPerSecond/src/me/roan/kps/Main.java index 6021c1d7..25bbb554 100644 --- a/KeysPerSecond/src/me/roan/kps/Main.java +++ b/KeysPerSecond/src/me/roan/kps/Main.java @@ -321,7 +321,7 @@ protected static final void mainLoop(){ max = totaltmp; } if(totaltmp != 0){ - avg = (avg * (double)n + (double)totaltmp) / ((double)n + 1.0D); + avg = (avg * n + totaltmp) / (n + 1.0D); n++; TotPanel.hits += currentTmp; System.out.println("Current keys per second: " + totaltmp + " time frame: " + tmp);