I doubt you're supposed to search for the password to look for duplicates. The common case is where you refuse to add a user (name) because it already exists.
So a function that took the array and a name to search for that returned where the name was found (or -1 for not found) would meet your needs.
After the user enters a name / password (or maybe even just after the name) you would search for the name and only add the new name if you didn't find it.
The prototype might look something like:
// The first argument should match your array declaration
// The second argument is the number of names already in the array
// The third argument is the name to search for
// The return values should be -1 for not found and the array index for the name if found
int findName(string names[], int numNames, const string & name);
If you use an STL collection class in place of the array in the call above, the numNames shouldn't be necessary, the STL classes can tell you how many items are in the collection.
You make an effort at writing the function and we can help you if you get stuck. If you get stuck, post your code along with a problem statement (i.e. "I expected ___ but I'm getting ___")
PS- When posting c++ code, please use c++ code tags[code=c++]
// Your code here
[/code]