mini spremembe
parent
2de39b3b20
commit
50518a326e
4
test.py
4
test.py
|
@ -3,7 +3,7 @@ from random import randint, choices
|
|||
#collection
|
||||
clltn = []
|
||||
|
||||
# card = title, due, interval
|
||||
# card = id, title, due, interval, owned_by, shared
|
||||
def generate_card (clltn=[], user="bob", shared=False):
|
||||
id = len(clltn) + 1
|
||||
title = "".join([chr(randint(ord('a'), ord('z'))) for i in range(5)])
|
||||
|
@ -14,7 +14,7 @@ def generate_card (clltn=[], user="bob", shared=False):
|
|||
return card
|
||||
|
||||
def generate_clltn (n_of_cards):
|
||||
clltn = [] #mogoče bi blo dobro met dictionary, sam žeštejemo len zgoraj...
|
||||
clltn = [] #mogoče bi blo dobro met dictionary, sam že štejemo len zgoraj...
|
||||
for n in range(n_of_cards):
|
||||
clltn.append(generate_card(clltn=clltn))
|
||||
return clltn
|
||||
|
|
Loading…
Reference in New Issue