Just rewrote econjack's:

```
memset(val, 0, sizeof(val) / sizeof(val[0]));
```

another way.

I was told to never trust a compiler initialising an array with specific values (0 for an int array in this case).

Maybe I should investigate that C++ garantees that int arrays are zeroed on creation.

Jacques

EDIT: on cppreference.com, I read:

The effects of zero initialization are:
If T is a scalar type, the object's initial value is the integral constant zero explicitly converted to T.
If T is an non-union class type, all base classes and non-static data members are zero-initialized, and all padding is initialized to zero bits. The constructors, if any, are ignored.
If T is a union type, the first non-static named data member is zero-initialized and all padding is initialized to zero bits.
If T is array type, each element is zero-initialized
If T is reference type, nothing is done.
As described in non-local initialization, static and thread-local variables that aren't constant-initialized (since C++14) are zero-initialized before any other initialization takes place. If the definition of a non-class non-local variable has no initializer, then default initialization does nothing, leaving the result of the earlier zero-initialization unmodified.

I will therefore trust that C++ compilers initializes int tables to zero from now on.

```
int val[6];
becomes
int val[6] = {};
```