I am writing a function that receives a one-dimensional array as an argument but I have a problem when I try to get the number of elements of the array. When I compile I get the error message as below. What is wrong?
Error 2 error C2228: left of '.size' must have class/struct/union d:\visual studio 2013 csce 221 projects\my_stack\my_stack\my_stack.cpp 92 1 My_stack
1 2 3 4 5 6
void f(int x[])
{
for (int i = 0; i <= x.size() - 1; i++)
{
}
}