From c8b89f4e0b8f90e5bc7df90c3b8bc0aea2dbe805 Mon Sep 17 00:00:00 2001 From: jacekpoz Date: Fri, 10 May 2024 22:09:45 +0200 Subject: [PATCH] make checkGenerator param final --- lab3/zad2/app/src/main/java/pl/jacekpoz/DHSetup.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lab3/zad2/app/src/main/java/pl/jacekpoz/DHSetup.java b/lab3/zad2/app/src/main/java/pl/jacekpoz/DHSetup.java index 1074d1c..5ee6253 100644 --- a/lab3/zad2/app/src/main/java/pl/jacekpoz/DHSetup.java +++ b/lab3/zad2/app/src/main/java/pl/jacekpoz/DHSetup.java @@ -34,7 +34,7 @@ public class DHSetup implements IDHSetup { } - private boolean checkGenerator(T a) { + private boolean checkGenerator(final T a) { long p = a.getCharacteristic() - 1; for (long q : sieve_of_eratosthenes((long)Math.sqrt(p))) { T b = this.constructor.apply(new GF.Params(a.getCharacteristic(), p / q));