Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Create a hierarchical class structure according to the UML 1. Create the following enums: a) Face: includes the 13 faces of a deck of playing
Create a hierarchical class structure according to the UML 1. Create the following enums: a) Face: includes the 13 faces of a deck of playing cards: ace, two, three... ten, jack, queen, king - include fields: display- the string representation of the face leg. A, 2-10,J,Q,K) points - the point scoring for each face: points face Ace face value 3 to 10 Jack or Queen King b) Suit: includes the suits of a deck of playing cards: clubs, spades, hearts, diamonds Include a display field that is the string representation of the suit. suit Clubs Spades Hearts Diamonds unicode \u2663 \u2660 \u2665 \u2666 2. The Card class has fields suit and a face of types Suit and Face, respectively. include one constructor: full-arg that assigns the passed suit and face Include getters for each and override the toString method to return a string in the format
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access with AI-Powered Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started