diff options
| author | E7-87-83 <fungcheokyin@gmail.com> | 2022-04-11 18:18:56 +0800 |
|---|---|---|
| committer | E7-87-83 <fungcheokyin@gmail.com> | 2022-04-11 18:18:56 +0800 |
| commit | 141b4ca6ec4695386b56813dc58815c03b92c161 (patch) | |
| tree | d5282eedbdab65a15825f101f28ef6c141b32612 | |
| parent | 315bd94a0a9a2652eaf40c5711a57ef75d109d96 (diff) | |
| download | perlweeklychallenge-club-141b4ca6ec4695386b56813dc58815c03b92c161.tar.gz perlweeklychallenge-club-141b4ca6ec4695386b56813dc58815c03b92c161.tar.bz2 perlweeklychallenge-club-141b4ca6ec4695386b56813dc58815c03b92c161.zip | |
negative integers are also not allowed
| -rw-r--r-- | challenge-159/cheok-yin-fung/java/Moebius.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/challenge-159/cheok-yin-fung/java/Moebius.java b/challenge-159/cheok-yin-fung/java/Moebius.java index f59c059631..fbd6b0af30 100644 --- a/challenge-159/cheok-yin-fung/java/Moebius.java +++ b/challenge-159/cheok-yin-fung/java/Moebius.java @@ -9,7 +9,7 @@ public class Moebius int N = 1; try { N = Integer.parseInt(args[0]); - if (N==0) + if (N<=0) throw new ArithmeticException(); } catch (Exception e) { System.err.print("Please use a positive integer "); |
