Card - Card.java Author Lewis and Loftus Solution to Programming Project 4.5 public class Card cfw public final static public final static public

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
//******************************************************************** // Card.java Author: Lewis and Loftus // // Solution to Programming Project 4.5 //******************************************************************** / public class Card { public final static int ACE = 1; public final static int TWO = 2; public final static int THREE = 3; public final static int FOUR = 4; public final static int FIVE = 5; public final static int SIX = 6; public final static int SEVEN = 7; public final static int EIGHT = 8; public final static int NINE = 9; public final static int TEN = 10; public final static int JACK = 11; public final static int QUEEN = 12; public final static int KING = 13; public final static int CLUBS = 1; public final static int DIAMONDS = 2; public final static int HEARTS = 3; public final static int SPADES = 4; private final static int NUM_FACES = 13; private final static int NUM_SUITS = 4; private int face, suit; private String faceName, suitName; //----------------------------------------------------------------- // Creates a random card. //----------------------------------------------------------------- public Card () { face = (int) (Math.random() * NUM_FACES) + 1; setFaceName();
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 05/17/2011 for the course COP 3530 taught by Professor Davis during the Spring '08 term at University of Florida.

Page1 / 4

Card - Card.java Author Lewis and Loftus Solution to Programming Project 4.5 public class Card cfw public final static public final static public

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online