#include<iostream>
#include<conio.h>
#include<windows.h>
#include<string>
using namespace std;
void main()
{
string name="bahria";
string check;
system("cls");
cout<<"\n enter the paswwod\n";
for(int i=0;i<name.length();i++)
{
check+=getch();
cout<<"*";
}
if(name == check)
{
cout<< "\n Corrected !!";
}
else
cout<<"\n Not Correct !!";
getch();
}
#include<conio.h>
#include<windows.h>
#include<string>
using namespace std;
void main()
{
string name="bahria";
string check;
system("cls");
cout<<"\n enter the paswwod\n";
for(int i=0;i<name.length();i++)
{
check+=getch();
cout<<"*";
}
if(name == check)
{
cout<< "\n Corrected !!";
}
else
cout<<"\n Not Correct !!";
getch();
}