Object-Oriented Programming Concepts and Applications
- Information Technology
- 11 pages
- Shared May 2025
An assignment explaining object-oriented programming principles with practical applications.
Preview 4 of 11 pages
See the first 4 pages exactly as they appear in the document.
Page 1 Read page 1 as text
Object - Oriented Programming Concepts and Applications Question 1.1. (TCO 1) Which of the following statements is/are true? (Points : 5) A. The implementation of a class should be hidden, as best practice. B. The state of an object is defined as the attributes and behaviors of that object. C. Striving for the fullest possible interface of a class, incorporating possible future class needs, is the goal when designing a class. D. An interface of a class defines what messages an object can respond to. All are true None are true Only A and D are true Question 2.2. (TCO 2) Which of the following components of a class definition can be overloaded? (Points : 5) Any object Constructor Static data members All of the above None of the above Question 3.3. (TCO 5) Which of the following method pairs are not examples of method overloading? (Points : 5) public void dance() public int dance(int x) public int walk(int x, int y) public void walk(int x, int y, int z) public int jump(int x, int y) public void jump(int y, int x) All of the above None of the above Question 4.4. (TCO 1) Which of the following statements is/are true? (Points : 5) You can create sub - classes and sub - objects. By using the keyword class in your program, memory is allocated for the object being defined. In object - oriented programming we design the program as a set of cooperating methods. None of the above Question 5.5. (TCO 1) Which of the following would be the most appropriate choice for a method in a Computer class? (Points : 5) monitorSize reboot processorType keyboard
Page 2 Page 3 Read page 3 as text
Question 6.6. (TCO 2) Which of the following statements is/are true? (Points : 5) A. The compiler generated default constructor does the exact same job as any user defined default constructor B. A common use of information hiding is to hide the physical storage layout of data. C. A private (helper) method is part of a class's implementation. All of the above Only B and C Question 7.7. (TCO 2) You are given a Shape class that was designed with the concept of a black box in mind. You need to integrate the Shape class into your own code. Which of the following statements are true? (Points : 5) You need to analyze each method's implementation that you plan to use in order to understand it thoroughly. You need to figure out the inputs and outputs that are associated with the class. You may have to modify the internal processing to meet the needs of your specific class. Without a properly constructed UML diagram you cannot be sure how the new class will integrate with your code. Question 8.8. (TCO 2) Given a private string attribute called homeState, which of the following are proper pseudocode implementations for a getter and a setter? (Points : 5) string getHomeState(){return homeState } int setHomeState(string newHomeState){return homeState } void getHomeState(){return homeState } void setHomeState (int newHomeState){homeState = newHomeState} string getHomeState(){return homeState } void setHomeState (string newHomeState){ homeState = newHomeState} string getHomeState (){homeState = newHomeState} void setHomeState (string newHomeState){ homeState = newHomeState} Question 9.9. (TCO 2) You are tasked to create an EntertainmentSystem class and you want to minimize data dependencies. You also need to protect specific attributes from outside entities. What object - oriented concept(s) would you use to accomplish these go als? (Points : 5) Composition of classes Universal access to methods Inheritance Encapsulation All of the above Question 10.10. (TCO 4) Select the false statement regarding inheritance. (Points : 5) A child class can have more functionality than parent class. A child class can itself be parent class. Common functionality needs to be designed in the parent class. Parent classes are usually more specific than child classes.
Page 4 Read page 4 as text
Question 11.11. (TCO 4) A Lamp class, LightBulb and OilLamp class have what type of relationships? (Points : 5) The Lamp is a LightBulb, and the Lamp is an OilLamp. The LightBulb has an OilLamp, and the OilLamp is a Lamp. The Lamp has a LightBulb, and the OilLamp is a Lamp The LightBulb has an OilLamp, and the Lamp is an OilLamp. Question 12.12. (TCO 3) Which of the following is true about identifying a class based on a set of requirements? (Points : 5) After the requirements are documented, the process of identifying classes can begin. One way to identify classes is to identify nouns in the problem analysis. Responsibilities of each class need to be identified after classes are identified. All of the above Question 1.1. (TCO 3) What does SOW stand for in the object - oriented design process? (Points : 5) Sequence of work Structure of work Statement of work None of the above Question 2.2. (TCO 4) What are the benefits to create another derived class instead of adding new functionalities to the program? (Points : 5) Saves time on debugging the program Simplifies testing No need to re - test the previously written class All of the above None of the above Question 3.3. (TCO 6) What is polymorphism? (Points : 5) An advanced form of inheritance A single usefulness for program specificity One interface, many implementations Data hiding Question 4.4. (TCO 7) Which of the following statements are false? (Points : 5) Interfaces specify a contract that must be respected by programmers implementing the interface. Interfaces specify one or more method signatures and at least one implementation. Interfaces can be used in some object - oriented languages to implement a form of multiple inheritance.
7 more pages in the full document
Unlock it once and it stays in your library, ready to chat with or turn into flashcards.
Unlock the full documentMore Information Technology study materials
See all
Exam GuidesTest Bank for Managing and Using Information Systems: A Strategic Approach, 7th Edition (Chapters 1-13)
Information Technology
452 pages149downloadsFeb 2025
Exam GuidesTest Bank for Essentials of MIS, 12th Edition
Information Technology
342 pages146downloadsFeb 2025
Exam GuidesA+ Guide to Hardware, 9th Edition Test Bank
Information Technology
116 pages142downloadsFeb 2025
Textbook GuidesSolution Manual for Essentials of System Analysis and Design, 4th Edition
Information Technology
282 pages140downloadsFeb 2025
Textbook GuidesGuide To Networking Essentials, 7th Edition Solution Manual
Information Technology
48 pages139downloadsFeb 2025
Past Exams2023-2024 SOPHOS FIREWALL V19.5 Practice Exam with Answers (75 Solved Questions)
Information Technology
7 pages134downloadsFeb 2025
Class NotesLecture Notes for CCNP Enterprise: Core Networking (ENCOR) v8 Lab Manual, 2nd Edition
Information Technology
1089 pages123downloadsFeb 2025
Class NotesLecture Notes for Adobe XD Classroom in a Book (2020 release)
Information Technology
66 pages118downloadsFeb 2025
Study this document with CramX
Once it is in your library, every tool can work from it.

