Learn R Programming

mosaic (version 0.2-3)

cards: Standard Deck of Cards

Description

A character vector with two or three character representations of each card in a standard 52-card deck.

Usage

data(cards)

Arguments

Details

The 2 of clubs is represented as "2C", while the 10 of diamonds is "10D".

Examples

Run this code
deal(cards, 13)        # bridge hand
deal(cards, 5)         # poker hand
shuffle(cards)         # shuffled deck

Run the code above in your browser using DataLab