mirror of
https://github.com/django-q2/django-q2.git
synced 2026-09-26 01:58:11 +08:00
19 lines
340 B
Python
19 lines
340 B
Python
# simple countdown, returns nothing
|
|
def countdown(n):
|
|
while n > 0:
|
|
n -= 1
|
|
|
|
def count_letters(tup):
|
|
total = 0
|
|
for word in tup:
|
|
total += len(word)
|
|
return total
|
|
|
|
def count_letters2(obj):
|
|
return count_letters(obj.get_words())
|
|
|
|
def result(obj):
|
|
print('RESULT HOOK {} : {}'.format(obj.name, obj.result))
|
|
|
|
|