Question: Need some help to complete this JavaScript: Please no button. It should directly display.... 2. (5 marks) Using an array, create a standard deck of
Need some help to complete this JavaScript:
Please no button. It should directly display....
2. (5 marks) Using an array, create a standard deck of cards (52 cards). Create a function that randomly draw 2 cards and displays them. The array code for the deck of cards is: var suits = ["Hearts", "Spades", "Clubs", "Diamonds"]; var numbers = ["A","2","3","4","5","6","7","9","9","10", "J","0", "K"]; Your display should look similar to the display shown in Figure 2. Part 1 Question 2 Card 1 is: 7 of Clubs Card 2 is: Q of Clubs Figure 2. Display for Part 1 Question 2
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
