import java.util.*;
public class Main
{
public static void main(String[] args)
{
String user, pass;
int count = 0;
do
{
System.out.print("Enter username: ");
user = new Scanner(System.in).nextLine();
System.out.print("Enter password: ");
pass = new Scanner(System.in).nextLine();
count++;
} while (((!user.equals("user")) || (!pass.equals("password"))) && (count != 5));
if (count == 5)
{
System.out.print("Login attemp fail!");
}
else
{
System.out.print("Password correct!");
}
}
}