> For the complete documentation index, see [llms.txt](https://liuzhenglaichn.gitbook.io/algorithm/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://liuzhenglaichn.gitbook.io/algorithm/cpp/array.md).

# Array

Using array `int[]` is more performant than `vector<int>`.

The following trick can initialize the array with customized values.

```
int A[10] = { [0] = 0, [1 ... 9] = INT_MAX };
```

See: <https://www.geeksforgeeks.org/designated-initializers-c/>
