Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

1. (TCO 1) Which of the following would be the most appropriate choice for a met

ID: 3560788 • Letter: 1

Question

1. (TCO 1) Which of the following would be the most appropriate choice for a method in a Cylinder class? (Points : 5)        InputRadius()
       Volume()
       Radius()
       Area() Question 2.2. (TCO 1) Object-oriented programming generally does NOT focus on _____. (Points : 5)        A. separating the interface from the implementation
       B. client side access to implementation details
       C. information hiding
       D. ease of program modifiability
       All of the above
       None of the above
       Only A, C, and D Question 3.3. (TCO 2) Which of the following components of a class definition do not have a return type?(Points : 5)        Public member methods
       Accessor/mutator methods
       Constructors
       Private member methods
       None of the above Question 4.4. (TCO 2) Which of the following statements is/are true? (Points : 5)        A. A default constructor is automatically created for you if you do not define one.
       B. A static method of a class can access non-static members of the class directly.
       C. An important consideration when designing a class is identifying the audience, or users, of the class.
       None of the above
       Only A and C Question 5.5. (TCO 5) Which of the following method pairs are not examples of method overloading? (Points : 5)        A. public void Bake() ; public int Bake()
       B. public int Mix(int x, int y) ; public int Mix(int y, int x)
       C. public int Shake(int x, int y) ; public int Shake(int x, int y, int z)
       None of the above
       Only A and B Question 6.6. (TCO 1) Which of the following statements is/are false? (Points : 5)        By using the keyword class in your program, memory is allocated for the object being defined.
       Method overloading is the basic concept of the object-oriented paradigm.
       Objects are created during program execution but are never destroyed.
       All of the above Question 7.7. (TCO 2) Assume you implemented a class called Automobile last year. You made sure to design Automobile to include the concept of encapsulation. Now, you need to change the name of one of your private class attributes. Because you used the concept of encapsulation and followed best practices when designing your class, only the _____ and _____ need to be changed. (Points : 5)        getters; setters
       access modifiers; constructors
       data type; return values
       public attributes; private methods
       None of the above Question 8.8. (TCO 2) A _____ is a term used to describe a system that can be understood solely based on its inputs, the resulting outputs and _____. (Points : 5)        class; a detailed understanding of its implementation
       class; a basic understanding of its implementation
       black box; a detailed understanding of its implementation
       black box; a basic understanding of its implementation

Question 9.9. (TCO 2) A class is designed with two public attributes: attributeOne and attributeTwo. attributeOne is an integer data type while attributeTwo is a string data type. Which pseudocode representation(s) of setters would be appropriate for this class? (Points : 5)        A. int setAttributeOne(int newAttributeOne)
     {
           return attributeOne
     }
       B. void setAttributeOne(int newAttributeOne)
    {
             attributeOne = newAttributeOne
    }
       C. string setAttributeTwo (int newAttributeTwo)
    {
               attributeTwo = newAttributeTwo      
    }
       D. void setAttributeTwo ()
    {
          attributeTwo = 1. (TCO 1) Which of the following would be the most appropriate choice for a method in a Cylinder class? (Points : 5)        InputRadius()
       Volume()
       Radius()
       Area()

Explanation / Answer

1.Volume()
2. Only A, C, and D
3 Private member methods
4.Only A and C
5.A. public void Bake() ; public int Bake()
6.All of the above
7.public attributes; private methods
8. black box; a detailed understanding of its implementation
9Both A and C
10An Interface represents a specific type of class inheritance.
11. A, B, and C
12. base classes; abstract methods
13.Derive a new Manager class from the first Employee class and add it there.
14.The WaterSkier has-a Boat, and the SkiBoat is-a Boat.
15. All of the above

page 2.
1.GrandParent, Parent, Child
2.Inheritance
3.Animals
4.All of the above
5. All of the above
6. Using namespaces to create global types
7. int GetWeight (){return weight;}, void SetWeight (int weight){this.weight = weight;}
8. public abstract void Drive();
9. 3