Сообщество IT-специалистов
Ответы на любые вопросы об IT
Профессиональное развитие в IT
Удаленная работа для IT-специалистов
def func(element): for child in element: if len(child) != 0: # your code else: func(child)
{% for row in rows %} <tr> <td>{{row.id}}</td> <td>{{row.name}}</td> <td>{{row.final}}</td> </tr> {% endfor %}
import random text = input() textInt = random.randint(len(text), len(text)*2)
[[4, 3], [11, 1], [5, 2], [7, 6]]
import time def some_func(): while True: if not input(): print("OK") time.sleep(1) else: Name = str(input("Какой то текст:")) some_func()
import time def some_func(): while True: print("OK") time.sleep(1) Name = str(input("Какойто текст:")) some_func()
def some_func(): while True: print("OK") Name = str(input("Какойто текст:")) some_func()
mass = [ [1,2], [4, 5], [5, 6], [7, 8] ] result = [] for elem in mass: for i in range(len(elem)): result.append(elem[i]) print(result)
one = [1,2,3,4,5] two = ['a','b','c','d','e'] result = [] for i in range(len(one)): result.append(one[i]) result.append(two[i]) print(result)
import ibm_db_dbi as db conn = db.connect("DATABASE=name;HOSTNAME=host;PORT=60000;PROTOCOL=TCPIP;UID=username;PWD=password;", "", "")