1
0
forked from tdwojak/Python2017
This commit is contained in:
Przemysław Kaczmarek 2017-11-28 18:44:32 +01:00
parent 2438b456f4
commit 9115943f9c

View File

@ -6,7 +6,10 @@ Napisz funkcję char_sum, która dla zadanego łańcucha zwraca
sumę kodów ASCII znaków.
"""
def char_sum(text):
pass
results=0
for letter in text:
results+=ord(letter)
return results
def tests(f):
inputs = [["this is a string"], ["this is another string"]]