human
Solve the following python programming problem given the following code:
# 30 marzo 2015
# Daniele
# Matrici
# GPL 3

"""
class Matrix with operations.
"""

from __future__ import division, print_function   # for compatibility with 2.x
import random

def matr_zero(rows, cols):
    """Return a bidimensional matrix of zeros.
>>> m_0 = matr_zero(3, 4)
>>> print(m_0)
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]]
    """
    return [[0 for i in range(cols)] for r in range(rows)]

def matr_random(rows, cols, mi, ma):
    """Return a bidimensional matrix of random numbers.
>>> m_0 = matr_random(3, 4, 0, 10)
>>> print(m_0)                      # doctest: +ELLIPSIS
[[..., ..., ..., ...], [..., ..., ..., ...], [..., ..., ..., ...]]
    """
    return [[random.randrange(mi, ma) for i in range(cols)] for r in range(rows)]

def vect_add(v0, v1):
    """Return vectors sum.
>>> print(vect_add([2, 4, 6], [3, 5, 0]))
[5, 9, 6]
    """
    return [a+b for a, b in zip(v0, v1)]

def vect_mul(v0, v1):
    """Return vectors scalar product.
>>> print(vect_mul([2, 4, 6], [3, 5, 0]))
26
    """
    return sum([a*b for a, b in zip(v0, v1)])

class Matrix():
    """Matrix class."""
    def __init__(self, matr):
        """Matrix init.
>>> m_0 = Matrix(matr_zero(4, 3))
>>> print(m_0.rows, m_0.cols)
4 3
>>> print(m_0.matr)
[[0, 0, 0], [0, 0, 0], [0, 0, 0], [0, 0, 0]]
        """
        self.matr = matr           # Attributo che contiene la matrice.
        self.rows = len(matr)      # numero di righe
        self.cols = len(matr[0])   # numero di colonne
        
    def __str__(self):
        """Matrix to string.
>>> m_0 = Matrix(matr_zero(2, 3))
>>> print(m_0)                     # doctest: +NORMALIZE_WHITESPACE
0  0  0
0  0  0
        """
        return "\n".join(["\t".join(map(str, r)) for r in self.matr])

    def row(self, index):
        """Return a Matrix row.
>>> m_0 = Matrix([[0, 1, 2], [1, 5, 9], [2, 7, 1], [3, 0, 4]])
>>> print(m_0.row(2))
[2, 7, 1]
        """
        return self.matr[index]

    def col(self, index):
        """Return a Matrix col.
>>> m_0 = Matrix([[0, 1, 2], [1, 5, 9], [2, 7,...
Given the above code, generate some markdown instructions for it.
assistant
#Here is the Python code you requested.

Ora abbiamo tutti gli elementi per completare la nostra libreria. 
Im metodo da seguire prevede alcuni sempli regole:

aggiungere una funzione alla volta;
scrivere la docstring con il test della funzione;
scrivere il codice della funzione correggendolo finché
il test non passa.

Seguendo queste indicazionicompletate la sguente libreria.