remove redundant code

This commit is contained in:
SowinskiBraeden committed 2025-02-16 15:52:36 -08:00
1 parent 8b942b5ddf
commit 83e5d02f4f
1 file changed
-4
@@ -46,9 +46,6 @@ public class Factorial {
int number = readPositiveInt();
if (number == 0) {
System.out.println("The factorial of 0 is 1.");
} else {
int product = 1;
for (int i = 2; i <= number; i++) {
product *= i;
@@ -58,5 +55,4 @@ public class Factorial {
+ product + "."
);
}
}
}