def main(): m1 = [[1, 2, 3], [4, 5, 6], [7, 8, 9]] m2 = [[6, 5, 0], [1, 3, 9], [0, 2, 1]] print(matrices.add_matrices(m1, m2)) print(matrices.sub_matrices(m1, m2)) print(figures.square_area(2)) print(figures.triangle_area(6, 3))
def test_square_area(): assert square_area(5) == 25 assert triangle_area(2, 4) == 4
def test_triangle_area(): assert triangle_area(2, 2) == 2
def test_pole_trojkat(): assert figures.triangle_area(2, 1) == 1
def test_triangle_area(): assert figures.triangle_area(10, 3) == 15
def test2(): assert triangle_area(3, 4) == 6
def test_triangle_area(): assert triangle_area(4, 4) == 8 assert triangle_area(1, 2) == 1
def test_triangle_area(): assert triangle_area(2, 4) == 4 assert triangle_area(3, 6) == 9
def test_triangle_area(): assert triangle_area(4, 6) == 0.5 * 4 * 6
def test_triangle_area(): assert triangle_area(1, 2) == 1 assert triangle_area(10, 20) == 100
def test1(): assert (figures.square_area(5) == 25) assert (figures.triangle_area(5, 8) == 20)