MCPcopy Create free account
hub / github.com/tensorflow/tfjs-examples / randomHand

Function randomHand

data-generator/game.js:62–68  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

60 * in sorted order.
61 */
62export function randomHand() {
63 const hand = [];
64 for (let i = 0; i < GAME_STATE.num_cards_per_hand; i++) {
65 hand.push(getRandomDigit());
66 }
67 return hand.sort((a, b) => a - b);
68}
69
70/**
71 * This function produces an array indicating the largest face value for

Callers 1

generateOnePlayFunction · 0.85

Calls 1

getRandomDigitFunction · 0.85

Tested by

no test coverage detected