0
0
Fork 0

zrobiono zadanie 11

This commit is contained in:
Michał Jaskuła 2018-06-02 17:38:54 +00:00
parent 7f4577f327
commit 1a4de39386
1 changed files with 7 additions and 2 deletions

View File

@ -9,7 +9,12 @@ Oba napisy będą składać się wyłacznie z małych liter.
"""
def common_chars(string1, string2):
pass
s1 = string1.replace(' ','')
s2 = string2.replace(' ','')
s1=set(s1)
s2=set(s2)
common = s1 & s2
return(sorted(list(common)))
def tests(f):
@ -23,4 +28,4 @@ def tests(f):
return "TESTS PASSED"
if __name__ == "__main__":
print(tests(common_chars))
print(tests(common_chars))