4 Java Exercise 8.1.pdf - 4/15/2021...

This preview shows page 1 out of 1 page.

4/15/20211/1Success!The value placed in the object using object.setthecard(38), was retrieved using object.getthecard( )Return to ExercisesYour Code ( with color highlights added ):public classPlayingCard{// DO NOT CHANGEprivateint thecard;publicint getthecard() {returnthecard;}publicvoid setthecard(newthecard) {if (newthecard>0&&newthecard<52)thecard=newthecard;}}// LAST LINE INSERT CODE ABOVE DO NOT CHANGEThe Instructions:
End of preview. Want to read the entire page?

Upload your study docs or become a

Course Hero member to access this document

Term
Fall
Professor
N/A
Tags
Subroutine, public class PlayingCard, thecard

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture