Homework Help! Urgent!

From: xscarsofdesirex (xscarsofdesirex_at_go4-dot-it.no-spam.invalid)
Date: 02/27/05

  • Next message: Patricia Shanahan: "Re: Homework Help! Urgent!"
    Date: 27 Feb 2005 13:59:33 -0600
    
    

    Probably a very simple program, but I am completely stumped.
    Any help in coding (even hints) for this would be GREATLY
    appreciated.
    If you would like to contact me directly, my AIM is XscarsofdesireX.

    Write a class called Card where each object represents a card. The
    class should have three instance variables.
    int myNum (stores a value 1 to 52)
    String mySuit (suit of the card- to be determined by myNum)
    String myValue (value of the card -1,....10,Jack, Queen, King, Ace)
    (use integer division for mySuit and % for myValue)

    The class should have a setValue() and setSuit(). They should be
    called in the constructor.

    Then write a class called DeckOfCards that holds 52 objects of type
    cards. Write methods that will assign each card a different number 1
    to 52, will shuffle the deck, will deal a card, and tell how many
    cards are left.

    Create a driver that will shuffle the deck, then pring out as many
    cards as the user wants dealt from the top of the deck.

     Posted Via Usenet.com Premium Usenet Newsgroup Services
    ----------------------------------------------------------
        ** SPEED ** RETENTION ** COMPLETION ** ANONYMITY **
    ----------------------------------------------------------
                    http://www.usenet.com


  • Next message: Patricia Shanahan: "Re: Homework Help! Urgent!"

    Relevant Pages

    • Clan Assamite Newsletter, July 2008
      ... vampires for the deck. ... Put this card on this magaji and untap him or her. ... Burn this card if this magaji attempts to block a vampire ... Tap this location to reduce the cost of a card you play by 1 pool ...
      (rec.games.trading-cards.jyhad)
    • Re: Clan Assamite Newsletter, July 2008
      ... vampires for the deck. ... Put this card on this magaji and untap him or her. ... Burn this card if this magaji attempts to block a vampire ... Tap this location to reduce the cost of a card you play by 1 pool ...
      (rec.games.trading-cards.jyhad)
    • Re: Malkavian Antitribu Newsletter, September 2007
      ... "If this action is blocked again, burn this card". ... I hope you aren't suggesting putting this in some deck specifically to ... +3 pool total just for an action that costs 1 blood. ... rocket, and it will add some huge bleeds to the pain (probably, with ...
      (rec.games.trading-cards.jyhad)
    • Official VEKN Ravnos Clan Newsletter - November 2005
      ... Malk bleed deck rather than the Ravnos Red Herring Tap and Bleed deck I ... help defend against weenie decks in this month's newsletter. ... There seems to be a card made just for this situation, Aranthebes, The ... Requires a ready vampire with a capacity below 6. ...
      (rec.games.trading-cards.jyhad)
    • Daughters of Cacophony Playbill, December 2005
      ... Daughters of Cacophony Playbill, December 2005 ... Vampire of the Month: ... Deck of the Month: ... When Yseult plays a card that requires Melpominee, ...
      (rec.games.trading-cards.jyhad)