I need a do while loop in this but when i try to put one in it errors alot could someone show me the proper placement please.
i use dev C++ compiler
//Login
#include <iostream>
#include <string>
#include <conio.h>
using namespace std;
int main()
{
cout << "\tWelcome to Login\n";
int security = 0;
string username;
cout << "\nUsername: ";
cin >> username;
string
password;
cout << "Password: ";
cin >> password;
if (username == "echoestroy" && password == "561654")
{
cout << "\nWelcome Echoestroy.";
security = 5;
}
if (username == "krissyk6" && password == "spike")
{
cout << "\nWelcome Krissyk6.";
security = 5;
}
if (username == "cjochoate" && password == "troy")
{
cout << "\nWelcome cjochoate.";
security = 5;
}
if (username == "guest" || password == "guest")
{
cout << "\nWelcome Guest.";
security = 1;
}
if (!security)
cout << "\nYour login has failed. Please check your username and password and try again";
getch();
return 0;
}