I have a string array with multiple names. I would like to check using an if statement if the user input is equal to any of the names.
For example:
names[5] = {'david','rares','tudor','john','jay'}
cin>>name;
And now i would like to check if name is equal to any of the elements in the array.
Very Bad Example:
if(name == names)
{
cout<<"you can use this name. Name: "<<name;
}