#include <array> struct S{ std::array<int, 5> b = {1, 2, 3, 4, 5};}; int main() { // your code goes here return 0;}
Standard input is empty
prog.cpp:5:42: error: array must be initialized with a brace-enclosed initializer std::array<int, 5> b = {1, 2, 3, 4, 5}; ^ prog.cpp:5:42: error: too many initializers for ‘std::array<int, 5u>’
Standard output is empty
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!