Simplified elapsed time calculating
This commit is contained in:
@@ -130,17 +130,14 @@ public class Main {
|
||||
System.out.println(usersArray.length() + " users found !");
|
||||
System.out.println("\nDecrypting passwords...\n");
|
||||
|
||||
float startTime = System.nanoTime();
|
||||
if (asynchronous) {
|
||||
float startTime = System.nanoTime();
|
||||
Parser.asyncGetPass(usersArray, rotation);
|
||||
float elapsedTime = (System.nanoTime() - startTime) / 1000000;
|
||||
System.out.println("Asynchronous elapsed time = " + elapsedTime + "ms");
|
||||
} else {
|
||||
float startTime = System.nanoTime();
|
||||
Parser.getPass(usersArray, rotation);
|
||||
float elapsedTime = (System.nanoTime() - startTime) / 1000000;
|
||||
System.out.println("Synchronous elapsed time = " + elapsedTime + "ms");
|
||||
}
|
||||
float elapsedTime = (System.nanoTime() - startTime) / 1000000;
|
||||
System.out.println("Asynchronous elapsed time = " + elapsedTime + "ms");
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user