+ 5
In C++ arrays are regarded as evil, why?
C++
2 Answers
+ 5
They are not safe and secure on their own, you have to manually keep track of their size and they can easily be used to cause buffer overflows and execute malicious code by corrupting the stack. In general it's better to use std::array or other STL containers that suit your need
+ 1
They are not evil, they just don't handle exceptions properly. They are advised to use if you know what you are doing and want maximum performance. Else, it is better to use STL to avoid bugs or exploits in your code.