Hey, i was wondering if i could get some help with this code, im not sure if i made a mistake or my design is just messed up. Its a program that ask's for a username and password. If access is granted both the values; username and password, need to be entered correctly. The problem is that if i enter a correct username but an incorrect password or vice-versa it shows access granted. I want to make it show the "access granted" text by entering both values correct only. Heres the code:
#include <iostream>
#include <string>
using namespace std;
Could you tell me how i would loop this program to limit the username and password set coming up only three times? An example would be say; to stop password crackers or something to limit their logins to only three attempts.