subject

Objective: Exercise step-wise refinement to produce an object-oriented way of sorting a hand of cards. This will make use of the object oriented-concept of an interface. It should also exercise understanding of an ArrayList. Use good coding habits to avoid hard-coding values, avoid user input errors and bullet-proof your code. Description: Have the user enter a hand of cards from the console in random order. Write a program that does a sort on a collection of a custom object (not using a library in C#) to order the cards. Then print to the console a least-to-greatest ordered arrangement of the cards. Playing cards are ordered by value then by suit. The program should take any number of cards, so this could be a hand of five, seven or thirteen cards. For values, assume: 2 < 3 < 4 < 5 < 6 < 7 < 8 < 9 <10< J < Q < K < A For suits, assume: Hearts < Diamonds < Clubs < Spades For simplicity of input this will only deal with capital letters, so if the user enters a lowercase letter, you should capitalize it. Example: If a user enters 7H (it means 7 of hearts), 3C (it means 3 of Clubs), AH (it means ace of hearts), and AS (ace of spades), then it should print 3C, 7H, AH, and AS.

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 17:30
Under which key category do the page up and page down keys fall? page up and page down keys fall under the keys category.
Answers: 1
question
Computers and Technology, 22.06.2019 23:30
Which of the following is not a symptom of chronic fatigue syndrome
Answers: 2
question
Computers and Technology, 23.06.2019 11:00
This chapter lists many ways in which becoming computer literate is beneficial. think about what your life will be like once you’re started in your career. what areas of computing will be most important for you to understand? how would an understanding of computer hardware and software you in working from home, working with groups in other countries and contributing your talents.
Answers: 1
question
Computers and Technology, 24.06.2019 00:30
Afiling system in which an intermediary source of reference, such as a file card, must be consulted to locate specific files is called a(n) system. a. shelf filing b. direct filing c. indirect filing d. shingling
Answers: 1
You know the right answer?
Objective: Exercise step-wise refinement to produce an object-oriented way of sorting a hand of card...
Questions
question
Mathematics, 28.04.2021 05:00
question
Mathematics, 28.04.2021 05:00
question
Mathematics, 28.04.2021 05:00
question
Mathematics, 28.04.2021 05:00
question
Chemistry, 28.04.2021 05:00
Questions on the website: 13722360