Given:20. public class CreditCard {21.22. private String cardID;23. private Integer limit;24. public String ownerName;25

Business, Finance, Economics, Accounting, Operations Management, Computer Science, Electrical Engineering, Mechanical Engineering, Civil Engineering, Chemical Engineering, Algebra, Precalculus, Statistics and Probabilty, Advanced Math, Physics, Chemistry, Biology, Nursing, Psychology, Certifications, Tests, Prep, and more.
Post Reply
answerhappygod
Site Admin
Posts: 899559
Joined: Mon Aug 02, 2021 8:13 am

Given:20. public class CreditCard {21.22. private String cardID;23. private Integer limit;24. public String ownerName;25

Post by answerhappygod »

Given:20. public class CreditCard {21.22. private String cardID;23. private Integer limit;24. public String ownerName;25.26. public void setCardInformation(String cardID,27. String ownerName,28. Integer limit) {29. this.cardID = cardID;30. this.ownerName = ownerName;31. this.limit = limit;32. }33. }Which statement is true?

A. The cardID and limit variables break polymorphism.
B. The code demonstrates polymorphism.
C. The ownerName variable breaks encapsulation.
D. The setCardInformation method breaks encapsulation. E. The class is fully encapsulated.
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!

This question has been solved and has 1 reply.

You must be registered to view answers and replies in this topic. Registration is free.


Register Login
 
Post Reply