<prompt> Kuzalisha algorithm ambayo shuffles deck ya kadi.  <response>: A simple algorithm to shuffle a deck of cards is as follows:1. First, create an array of 52 cards, initialized with values from 1 to 52, representing a standard deck of playing cards.2. Set a variable n equal to the length of the array 52 for a standard deck of playing cards.3. Use a for loop to iterate through the array of cards from the last index to the first.4. Within the for loop, generate a random integer r between 0 and i, where i is the current index of the for loop.5. Swap the values of the cards at indices i and r within the array.6. Continue iterating through the for loop, decrementing i with each iteration, until the loop has completed and all cards have been shuffled.In code, the algorithm would look like this:function shuffleDeckdeck let n deck.length; for let i n-1; i 0; i-- let r Math.floorMath.random i 1; let temp decki; decki deckr; deckr temp; return deck; 