phe.js
function setCardCodes(set) {
  const codeSet = new Set()
  for (const v of set) codeSet.add(cardCode(v))
  return codeSet
}
function setCardCodes(set) {
  const codeSet = new Set()
  for (const v of set) codeSet.add(cardCode(v))
  return codeSet
}
function setCardCodes ( set ) { const codeSet = new Set ( ) for ( const v of set ) codeSet . add ( cardCode ( v ) ) return codeSet }
Converts a set of cards to card codes.

@name setCardCodes
@function
@param {Set.<String>} set card strings set, i.e. `Set({'Ah', 'Ks', 'Td', '3c, 'Ad'})`
@return {Set.<Number>} card code set
Converts a set of cards to card codes .