You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

Password.java 611 B

2 years ago
12345678910111213141516171819202122
  1. package homework.pkg4;
  2. import java.security.MessageDigest;
  3. import java.util.Scanner;
  4. public class Password {
  5. public static void main( String[] args ) throws Exception {
  6. Scanner keyboard = new Scanner(System.in);
  7. String un, pw, encrypt_psswrd;
  8. MessageDigest digest = MessageDigest.getInstance("SHA-256");
  9. System.out.print("Please create a username: ");
  10. un = keyboard.nextLine();
  11. System.out.print("Please create a password: ");
  12. pw = keyboard.nextLine();
  13. System.out.println( "Your username is: " + un + ". Your password is: " + pw);
  14. }
  15. }

No Description

Contributors (1)