# Does mesh.triangles also return a copy of the triangle array?

So mesh.vertices returns a copy of the vertex array, so if you are accessing it more than a couple of times you should really store it in a local array to avoid excessive garbage being created. So if I have some code like this:

``````for(int i = 0; i < mesh.triangles.length; i+=3){
Vector3 v0Vec = mesh.vertices[mesh.triangles*];*
``````

Vector3 v1Vec = mesh.vertices[mesh.triangles[i + 1]];
Vector3 v2Vec = mesh.vertices[mesh.triangles[i + 2]];

}
Then I should really convert it to something like this:
Vector3[] verts = mesh.vertices;
for(int i = 0; i < mesh.triangles.length; i+=3){
Vector3 v0Vec = verts[mesh.triangles*];*
Vector3 v1Vec = verts[mesh.triangles[i + 1]];
Vector3 v2Vec = verts[mesh.triangles[i + 2]];

}
But does mesh.triangles do the same thing? Should my code really be more like this?:
Vector3[] verts = mesh.vertices;
int[] tris = mesh.triangles;
for(int i = 0; i < tris.length; i+=3){
Vector3 v0Vec = verts[tris*];*
Vector3 v1Vec = verts[tris[i + 1]];
Vector3 v2Vec = verts[tris[i + 2]];

}