I want to create array like this:
let arr = [0; length];
Where length is a usize
. But I get this error
E0307
The length of an array is part of its type. For this reason, this length
must be a compile-time constant.
Is it possible to create array with dynamic length? I want an array, not a Vec
.