1import java.util.Scanner;
2
3public class YourProjectName {
4
5 public static void main(String[] args) {
6 Scanner keyboard = new Scanner(System.in);
7
8 //D
9
10 String password1;
11 String password2;
12 String msg;
13
14 //E
15
16 System.out.println("Enter password: ");
17 password1 = keyboard.nextLine();
18
19 System.out.println("Repeat password: ");
20 password2 = keyboard.nextLine();
21
22 //P
23
24 if (password1.equals(password2)) {
25 msg = "Password matching!";
26 } else {
27 msg = "Password not match";
28 }
29
30 //S
31
32 System.out.println(msg);
33
34 }
35
36}