24 lines
336 B
Python
24 lines
336 B
Python
|
#!/usr/bin/env python3
|
||
|
|
||
|
def generatePasswort(name):
|
||
|
vokale = "aeiouäöüAEIOUÄÖÜ "
|
||
|
|
||
|
pw = ""
|
||
|
|
||
|
for n in name:
|
||
|
if n not in vokale:
|
||
|
pw += n
|
||
|
|
||
|
return pw
|
||
|
|
||
|
tests = [
|
||
|
"Isabell Bauer",
|
||
|
"Markus Müller",
|
||
|
"Annie Claasen",
|
||
|
]
|
||
|
|
||
|
for t in tests:
|
||
|
print(t, ":", generatePasswort(t))
|
||
|
|
||
|
print(generatePasswort(input("Name: ")))
|