# sam.rab3
# ex 1

a = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]
def summ_10(a: list) -> float:
    h = len(a)
    print(h)
    summ = 0
    for i in a:
        summ += i
    return summ
print(summ_10(a))

# ex 2
b = [0, 2, 0, 4, 2, 5, 0, 8, 0, 0]
def ziro_of_number(b: list) -> int:
    sum = 0
    for i in b:
        if i == 0:
            sum += 1
    return sum
print(ziro_of_number(b))

# ex 3

def lestnitsya(l: int) -> int:
    for i in range(1, l+1):
        k = ''
        for j in range(1, i+1):
            k += str(j)
        print(k)

lestnitsya(7)

# ex 4

def pirramide(n):
    for i in range(1, n+1):
        s = ' ' * (n - i)
        for k in range(1, i+1):
            s += str(k)
        print(s + s[n-2::-1])
pirramide(6)

# ex 5
#
# голова не варит, это задание не решил
