Test your basic knowledge |

Object Oriented Programming

Subject : it-skills
Instructions:
  • Answer 50 questions in 15 minutes.
  • If you are not ready to take this test, you can study here.
  • Match each statement with the correct term.
  • Don't refresh. All questions and answers are randomly picked and ordered every time you load a test.

This is a study tool. The 3 wrong answers for each question are randomly chosen from answers to other questions. So, you might find at times the answers obvious, but you will see it re-enforces your understanding as you take the test each time.
1. Returns a new string identical to this string except all uppercase letters are converted to their lowercase equivalent.






2. The classes of the Java standard class library are grouped into __________.






3. Variables that don't contain any data






4. declaration that creates a String variable that holds a reference to a String object; an object variable doesn't hold an object itself - it holds the address of an object






5. Before you use a variable __________it






6. Elements of input






7. Cast operator has _________ precedence to division






8. Returns all input remaining on the current line as a character string.






9. Returns a new string identical to this string except all lowercase letters are converted to their uppercase equivalent.






10. Methods that provide services to the client must be declared with public visibility so that they can be invoked by the client.






11. A null reference indicates that a variable does not refer to an object






12. A ________________ is immutable.






13. New memory space is reserved for that variable every time an instance of the class that is created.






14. How classes are created from other classes. the definition of one class can be based on another class that already exists. inheritance is a form of software reuse - capitalizing on the similarities between various kinds of classes that we want to cre






15. Four integer data types: byte - short - int - _____






16. The idea that we can refer to multiple types of related objects over time in consistent ways. it gives us the ability to design powerful and elegant solutions to problems that deal with multiple objects.






17. Constructor: creates a new pseudorandom number generator.






18. Modifier>type/void>identifier>parameters>method body






19. Two floating data types: float - _______






20. Occurs automatically when certain operators need to modify their opeands in order to perform the operation






21. When two variables contain the same address and therefore refer to the same object; one important implication of _________ is that when we use one ref to change an object - it is also changed for the other reference because there is really only one o






22. Eight primitive data types: four subsets of integers - two subsets of ________ - a character data type - and a boolean data type






23. A group of programming statements that is given a name. when a method is invoked - its statements are executed. a set of methods is associated with an object and defines its potential behaviors. to define the ability to make a deposit into a bank acc






24. Every object has two things: a state and a _____ of behaviors






25. If a class contains the _________ height - it should also probably contain the methods: getHeight and setHeight






26. An explicit data value used in a program






27. The fundamental characteristics that currently define the object. for example - part of a bank account's state is its current balance.






28. format for constants: all upper-case; separated by ________






29. Returns a new string that is identical with this string except that every occurrence of oldChar is replaed by newChar






30. Count++; count--






31. Provides generic formatting capabilities for numbers; you don't instantiate a NumberFormat object by using the "new" operator.






32. Five steps of problem-solving: ____________ the problem - Designing a solution - Considering alternatives to the solution and refining the solution - Implementing the solution - Testing the solution and fixing any problems that exist






33. The values passed into a method in an invocation; these are called the arguments to the method






34. Returns the next input token as the indicated type.






35. A set of classes that supports the development of programs






36. An object in Java - defined by the class String






37. Two categories of statements that control the flow of executing through a method: __________ and loops






38. A special method that has the same name as the class. After the "new" operator creates the object it is invoked to help set it up initially






39. Making it difficult - if not impossible - for code outside of a class to "reach in" and chnage the value of a variable that is declared inside that class.






40. Also called a selection statement b/c it allows us to choose which statement will be executed next.






41. Examples of Scanner ________: Scanner (InputStream source) - Scanner(File source) - Scanner(String source)






42. Instance data should be defined with what________ visibility






43. Provides read-only access to a particular value - e.g. getX where X is the value to which it provides access.






44. Automatically imported because they are fundamental and can be thought of as basic extensions to the language.






45. The act of creating an object using the "new" operator






46. ++count; -- count






47. Provide various methods related to the management of the associated primitive type. Used when we create an object that serves as a container to hold various types of other objects - and we want the object to hold a simple integer value. In this case






48. sides=10;






49. All numeric types are _______ - meaning both positive and negative values can be stored in them






50. Returns a new string that is a subset of this string starting at index offset and extending through endIndx-1;