Skip to content

Commit

Permalink
Implemented contains_illegal_letters function
Browse files Browse the repository at this point in the history
  • Loading branch information
micknudsen committed Dec 10, 2023
1 parent 60ac003 commit b5099bf
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions 2015/11/code.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,13 @@ def contains_increasing_straight(password: str) -> bool:
return False


def contains_illegal_letters(password: str) -> bool:
for letter in password:
if letter in ["i", "o", "l"]:
return True
return False


class TestCode(unittest.TestCase):
def test_contains_increasing_straight(self) -> None:
self.assertTrue(contains_increasing_straight(password="hijklmmn"))
Expand Down

0 comments on commit b5099bf

Please sign in to comment.