/in/foo.cc:6:8: error: expected ':' before ';' token
private;
^
/in/foo.cc:7:6: error: expected ';' at end of member declaration
int date10];
^~~~~~
/in/foo.cc:7:12: error: expected unqualified-id before ']' token
int date10];
^
/in/foo.cc:43:2: error: 'void IntArray::p()' conflicts with a previous declaration
}
^
/in/foo.cc:9:8: note: previous declaration 'int IntArray::p'
int p=0;
^
/in/foo.cc: In constructor 'IntArray::IntArray(int*, int)':
/in/foo.cc:15:4: error: 'date' was not declared in this scope
date[i] = a[i];
^~~~
/in/foo.cc: In member function 'int IntArray::BinSearch2(int, int, int)':
/in/foo.cc:23:6: error: 'date' was not declared in this scope
if(date[mid] == x)
^~~~
/in/foo.cc:25:5: error: no post-increment operator for type
p++;
^~
/in/foo.cc:28:6: error: 'date' was not declared in this scope
if(date[mid] > x)
^~~~
/in/foo.cc:30:5: error: no post-increment operator for type
p++;
^~
/in/foo.cc:33:6: error: 'date' was not declared in this scope
if(date[mid] < x)
^~~~
/in/foo.cc:35:5: error: no post-increment operator for type
p++;
^~
/in/foo.cc: In member function 'void IntArray::p()':
/in/foo.cc:41:7: error: invalid use of non-static member function 'void IntArray::p()'
cout<<p;
~~~~^~~
/in/foo.cc:39:7: note: declared here
void p()
^
/in/foo.cc:42:3: error: invalid use of member function 'void IntArray::p()' (did you forget the '()' ?)
p = 0;
^
/in/foo.cc: In function 'int main()':
/in/foo.cc:64:5: error: 'class IntArray' has no member named 'P'
A.P();
^
/in/foo.cc:63:7: warning: unused variable 'k1' [-Wunused-variable]
int k1 = A.BinSearch2(0, n-1, x);
^~
/in/foo.cc: In member function 'int IntArray::BinSearch2(int, int, int)':
/in/foo.cc:38:2: warning: control reaches end of non-void function [-Wreturn-type]
}
^