Commit 5ce7a1bd authored by rawan's avatar rawan

step3

parent 52734f86
......@@ -8,7 +8,7 @@ public class DescendingHackerThread extends Thread {
public DescendingHackerThread(Vault vault) {
this.vault = vault;
//A function that changes the name of the thread only to make it easier to track it while running
this.setName(this.getClass().getSimpleName());
}
......@@ -17,12 +17,8 @@ public class DescendingHackerThread extends Thread {
for (int x = MAX_PASSWORD; x >= 0; x--) {
if (vault.isCorrectPassword(x)) {
System.out.println("success " + this.getName() + "the correct password " + x);
System.exit(0);
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment