In the previous chapter, we defined a class to represent cards and used an array of
Card objects to represent a deck.
In this chapter, we take another step toward object-oriented programming by defining a class to represent a deck of cards. And we present algorithms for shuffling and sorting arrays.
The code for this chapter is in
Deck.java, which are in the directory
ch13 in the repository for this book. Instructions for downloading this code are in [Section 0.4].