Write a function that takes the coordinates of three points in the form of a 2d array and returns the perimeter of the triangle. The given points are the vertices of a triangle on a two-dimensional plane.
perimeter([[15, 7], [5, 22], [11, 1]]) ➞ 47.08
perimeter([[0, 0], [0, 1], [1, 0]]) ➞ 3.41
perimeter([[-10, -10], [10, 10 ], [-10, 10]]) ➞ 68.28