Languages such as Rust that lean on inference are an absolute joy to program in.
That said, there's the solution: type level integers.
(That also said, Rust's String type isn't an array, because it's mutable, so the size can't be a part of the type)
Languages such as Rust that lean on inference are an absolute joy to program in.