# Array of array, question

**URL:** <https://community.freefem.org/t/array-of-array-question/3130>\
**Category:** General Discussion\
**Created:** [April 21, 2024, 4:46pm UTC](https://community.freefem.org/t/array-of-array-question/3130 "2024-04-21T16:46:04Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![bcaval](https://avatars.discourse-cdn.com/v4/letter/b/d26b3c/32.png) [@bcaval](https://community.freefem.org/u/bcaval)\
**Post date:** [April 21, 2024, 4:46pm UTC](https://community.freefem.org/t/array-of-array-question/3130/1 "2024-04-21T16:46:04Z")

</div>

Hello,  
On the help guide I found :  
// Array of Array  
real [int][int] V(10);  
matrix[int] B(10);

real [int, int][int] A(10);

Do you have examples how to use the last line ?  
Indeed I would like to use the two first indexes for tensorial properties, and the third index linked to the material domain.

Thanks in advance,  
Bruno

---

<div class="post-metadata">

**Author:** ![prj](https://avatars.discourse-cdn.com/v4/letter/p/ecae2f/32.png) [@prj](https://community.freefem.org/u/prj)\
**Post date:** [April 21, 2024, 4:59pm UTC](https://community.freefem.org/t/array-of-array-question/3130/2 "2024-04-21T16:59:06Z")

</div>

Here is one such example.

```auto
real [int, int][int] A(10);

A[0].resize(10, 20);
A[0] = 2.0;
cout << A[0] << endl;
A[8].resize(20, 10);
A[8] = -1.0;
cout << A[8] << endl;

```

---

<div class="post-metadata">

**Author:** ![bcaval](https://avatars.discourse-cdn.com/v4/letter/b/d26b3c/32.png) [@bcaval](https://community.freefem.org/u/bcaval)\
**Post date:** [April 21, 2024, 7:51pm UTC](https://community.freefem.org/t/array-of-array-question/3130/3 "2024-04-21T19:51:39Z")

</div>

Thanks a lot, it works!  
Good evening.
