Preview

01 - Introduction to OOP

 1. Some people believe that OOP is a more intuitive programming style to learn, because people find it easy to reason about objects and relationships between them

  FALSE

  TRUE

 2. Object-oriented programming allows us to model the real world and the vocabulary it uses is deeply rooted in us, way before computers were a thing. Fill in the blanks
The greek philosopher .................. (in his theory of forms)
believed that the real universe was all the ideas
and abstractions we have about different things
we observe and our observable world was merely made of 
imperfect shadows or instances of these ideas/grand templates.
plato_oop.jpg

  Leon

  Jesus

  Hercules

  Plato

 3. Object Orientated Programming (OOP) is one of the many programming paradigms. A paradigm is….

  referring to the C language

  an approach to solving a problem

  referring to machine code (1s and 0s)

  a particular type of low level language

 4. OOP is based around the idea that everything is an object. Objects have …..

  bases and subbases

  attributes and methods

  directories and templates

  failures and kernels

 5. OOP basically creates ……………………which are called classes.

  procedures

  directories

  functions

  templates

 6. Each class can also be thought of as a ……………….

  function

  attribute

  blueprint

  machine code replica

 7. In OOP vocabulary, an object is …………

  an attribute of an instance

  a method of a class

  an instance of a class

  a class of an instance

 8. Classes can be used to create objects. Many instances of a class can be present as the program runs.

  TRUE

  FALSE

 9. A game, for example, may have a 'player' class. Many ……………………………

  classes can be created from the object

  player objects (instances of the player class) can be created

  All of the above are true

  objects cannot be created from a single class

 10. Remember, a class is a blueprint, and it will usually contain the ….

  library functions and insertions

  loops and if statements within it

  attributes (variables) and methods (functions - what it will do)

  variables and CPU directory

 11. Which of the following is a popular OOP language

  Python

  C++

  Java

  All of the above

 12. Objects created for Object Oriented Programs can easily be reused in other programs. This is _____________________-

  a security breach

  an advantage of OOP

  a disadavtange of OOP

  None of the above

 13. Another benefit of OOP is that once an Object is created, knowledge of its implementation is not necessary for its use

  TRUE

  FALSE

 14. OOP also provides a clear_______________ for programs which makes it good for defining abstract datatypes in which implementation details are hidden

  linear sequence of binary bits

  non modular structire

  modular structure

  None of the above

 15. Creating a class brings an exceptional amount of “organizational power” to our programs, and to our thinking. We can group together methods and attributes and reuse them.

  TRUE

  FALSE