6

I have the problem with the following code:

message is vector<unsigned char>

vector<unsigned char>::iterator pos = message.begin();
vector<unsigned char>::iterator start = message.begin();
vector<unsigned char>::iterator end = message.end();

pos = find(start, end, ' ');

I got the error:

error: no matching function for call to ‘find(std::vector<unsigned char>::iterator&, std::vector<unsigned char>::iterator&, char)’
Sam Miller
  • 23,808
  • 4
  • 67
  • 87
M.K.
  • 640
  • 1
  • 10
  • 23

1 Answers1

11

Are you including <algorithm>?

Peter Alexander
  • 53,344
  • 14
  • 119
  • 168