diff options
author | Christopher Burns | 2010-06-28 23:52:44 -0500 |
---|---|---|
committer | Christopher Burns | 2010-06-28 23:52:44 -0500 |
commit | 28417ef50170aa5696b5903f1289431b381b5c9e (patch) | |
tree | fc271daaa162eb321f0dc42d31d2fa4662534eca | |
parent | d05a2e97f02d6c8f600564d34634badea82950b0 (diff) | |
download | workshops-28417ef50170aa5696b5903f1289431b381b5c9e.tar.gz workshops-28417ef50170aa5696b5903f1289431b381b5c9e.tar.bz2 workshops-28417ef50170aa5696b5903f1289431b381b5c9e.zip |
REF: Minor format changes to exercise
--HG--
branch : scipy2010
-rw-r--r-- | day1/exercise/even_perfect_4.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/day1/exercise/even_perfect_4.py b/day1/exercise/even_perfect_4.py index 7910acf..c582a24 100644 --- a/day1/exercise/even_perfect_4.py +++ b/day1/exercise/even_perfect_4.py @@ -5,7 +5,8 @@ def is_perfect_square(n): return i * i == n def all_digits_even(n): - if n < 0: n = -n + if n < 0: + n = -n while n > 0: if n % 2 == 1: return False |