Question: Please make the blackjack 21 card game in JAVA: Make two classes: BlackJackMain and BlackJackMethods. In BlackJackMain class, write a program which will ask the

Please make the blackjack 21 card game in JAVA: Make two classes: BlackJackMain and BlackJackMethods. In BlackJackMain class, write a program which will ask the user if they have ever played this game before. If the user says no, ask them to create a username and password and filewrite it. -The password must be at least 6 characters long -must contain at least one capital letter -must contain at least one lower case letter -and must contain at least 1 number If user says yes, ask them for their username and password. FileRead it to check if the username or password they have entered matches with what is in the file. If it matches, let them play the game. If not, then give them 3 extra tries to enter the password. If they still fail to login, end the program by saying "You have failed to login". Once they are allowed in, start the game off by giving the user $100 and asking them how much they want to bet. for instance, if the user says 50. Then start the game by giving player 1 (the user) receive two cards and player 2 (the dealer and played by the computer) two cards also. Give the player the option to either hit or stand. The first player may take one more card, then one more, trying to get as close to 21 total as possible. When the first player stops taking cards, the second player takes cards to get closer to 21. If either player goes over 21, they lose immediately. If both players stay under 21, the player with the higher total wins. At the beginning, if a player has 21 in two cards, that is "Black Jack" and they win immediately. The totals are added-up as follows: Cards 2-10 count their face value (rank). Face cards (king, queen, jack) count 10. An ace counts either 11 or 1, depending on which is better for the player.

Examples:

10 , 8 --> 18

Jack, Queen --> 20

Ace , 6 --> either 7 or 17

Queen , Ace --> Black-Jack (win)

Queen , 5 , 8 --> 23 (busted = lose)

In BlackJackMethods have all the methods necessary to run the game. You can add some things to the BlackJackMain class as well if need to.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!