'i am unable to initilize vector with initilize elements

I am unable to initialize the vector with initial elements.

I am receiving this error:

no instance of constructor "std::__1::vector<_Tp, _Allocator>::vector [with _Tp=int, _Allocator=std::__1::allocator]" matches the argument list

snapshot of my code and error

I am using VS Code on a MacBook Air M1.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source