# Function with Matrix input [closed]

Hello Guys i have the following problem.

I want to write a function whose input is a Matrix. A small example:

```
def Dimension(Matrix):
n = Matrix.nrows()
return n
A = ([1,0,0],[0,1,0],[0,0,1])
print Dimension(A)
```

but then i get :

```
AttributeError: 'tuple' object has no attribute 'nrows'
```

How can I write i function that has an Matrix as input?

It would be better if you call the function with a matrix as input and not a tuple

Oops... that was quite some fail... Sorry :)

@bruno171092 The forum is exactly made for questions! If you are happy with my comment, could you close the question?