This code was supposed to check 2 usernames and password matches but I want it to be able to say if either the username or password is wrong which is near the bottom of the code. can someone tell me how I can fix the bottom if statement
[code]
[/c#include <iostream>
#include <string>
using namespace std;
int main ()
{
string username;
string password;
cout << "Please Enter your Username: " << "\n";
cin >> username;
cout << "Please enter your password" << "\n";
cin >> password;
I tried your code to replace my else if statement but it would still not execute the cout the program will just end when i click enter after putting in the wrong password