diff --git a/src/factor/factor.rs b/src/factor/factor.rs index 8f78e8739..b037be020 100644 --- a/src/factor/factor.rs +++ b/src/factor/factor.rs @@ -94,6 +94,9 @@ fn table_division(mut num: u64, factors: &mut Vec) { num /= 2; factors.push(2); } + if num == 1 { + return; + } if is_prime(num) { factors.push(num); return;