How can i fix this line?

Apr 6, 2022 at 10:51pm
unsigned Sum(vector<int> GivenVector)
{
//stuff
}


is giving me the following errors:

Calculate.cpp:50:14: error: ‘vector’ was not declared in this scope
unsigned Sum(vector<int> GivenVector)
^
Calculate.cpp:50:21: error: expected primary-expression before ‘int’
unsigned Sum(vector<int> GivenVector)

how can i solve this issue? i already have the proper #includes.
Apr 6, 2022 at 11:27pm
#include vector and use
std::vector to get the proper namespace
or a using statement, eg using std::vector
Last edited on Apr 6, 2022 at 11:28pm
Topic archived. No new replies allowed.