# Output subscriber name magsarrayxgetsubscribername

• Homework Help
• 15
• 100% (71) 71 out of 71 people found this document helpful

Course Hero uses AI to attempt to automatically extract content from documents to surface to you and others so you can study better, e.g., in search results, to enrich docs, and more. This preview shows page 11 - 15 out of 15 pages.

output “Subscriber Name: ”,magsArray[x].getSubscriberName()output “Magazine Name: ”, magsArray[x].getMagazineName()
##### We have textbook solutions for you!
The document you are viewing contains questions related to this textbook.
Chapter 1 / Exercise 5
Java Programming
Farrell
Expert Verified
Programming Logic and Design, 7eSolutions 10-12output “Months Remaining: ”,magsArray[x].getMonthsRemaining()x = x + 1endwhilex = 0while x > MAXmagsArray[x].setMonthsRemaining(magsArray[x].getMonthsRemaining()-1)x = x + 1endwhilex = 0while x > MAXoutput “The information entered forMagazineSubscription ”, x+1,“ after one was subtracts from months”output “Subscriber Name: ”,magsArray[x].getSubscriberName()output “Magazine Name: ”, magsArray[x].getMagazineName()output “Months Remaining: ”,magsArray[x].getMonthsRemaining()x = x + 1endwhilestopFind the Bugs9.Your downloadable student files for Chapter 10 include DEBUG10-01.txt,DEBUG10-02.txt, and DEBUG10-03.txt. Each file starts with some comments thatdescribe the problem. Comments are lines that begin with two slashes (//). Followingthe comments, each file contains pseudocode that has one or more bugs you must findand correct.
10. a. Playing cards are used in many computer games, including versions of suchclassics as Solitaire, Hearts, and Poker. Design a Card class that contains a string datafield to hold a suit (spades, hearts, diamonds, or clubs) and a numeric data field for avalue from 1 to 13. Include get and set methods for each field. Write an applicationthat randomly selects two playing cards and displays their values.
Programming Logic and Design, 7eSolutions 10-13
b. Using two Card objects, design an application that plays a simple version of thecard game War. Deal two Cards—one for the computer and one for the player.Determine the higher card, then display a message indicating whether the cards areequal, the computer won, or the player won. (Playing cards are considered equalwhen they have the same value, no matter what their suit is.) For this game, assume
Programming Logic and Design, 7e

Course Hero member to access this document

End of preview. Want to read all 15 pages?

Course Hero member to access this document

Term
Fall
Professor
N/A
Tags
Subroutine, Return statement, Void type, National identification number
##### We have textbook solutions for you!
The document you are viewing contains questions related to this textbook.
The document you are viewing contains questions related to this textbook.
Chapter 1 / Exercise 5
Java Programming
Farrell
Expert Verified