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. 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






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






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






4. The order in which statements are executed in a running program






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






6. When a variable is declared inside a method






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






8. All wrapper classes are defined in ___________






9. Allows all classes in the java.util package to be referenced in the program without qualfying each reference.






10. Elements of input






11. Before you use a variable __________it






12. Attempts to find the next occurence of the specified pattern - ignoring delimiters






13. The declarations of object variables have a similar structure to the declaration of _______________






14. Returns a new string consisting of this string concatenated with str.






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






16. Part of the java.util class; picks a number at random out of a range of values.






17. The names of the parameters in the header of the method declaration






18. Constructor: creates a new string object with the same characters as str.






19. Cast operator has _________ precedence to division






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






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






22. Part of the standard Java class library - provides convenient methods for reading input values of various types. the input can come from various sources - including data typed interactively by the user or data stored in a file; the Scanner class can






23. ____________ is instantiated in the traditional way using the new operator.






24. Defined and then used as the type of a variable when it is declared; establishes all possible values of a variable of that type by listing - or enumerating - them.






25. Delimited by double quotation characters






26. Boolean type conversions are ___________






27. Begins with a backslash character ""






28. The blueprint of an object. establishes the kind of data an object of that type will hold and defines the methods that represent the behavior of such objects. however - a class contains no space to store data. each object has space for its own data -






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






30. A ________________ is immutable.






31. Sets the scanner's delimiting pattern.






32. The only purpose of a private method is to help other methods of the class do their job. they are referred to as _________






33. 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






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






35. Declared in a class but not inside any particular method






36. An explicit data value used in a program






37. Three ways in which Java conversions occur: _________ conversion - promotion - casting






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






39. System.out object represents an output device or file; we send the println message to the System.out object to request that some text be printed






40. Methods in the Math class are ______






41. An object should be self-governing - meaning that the instance data of an object should be modified only by that object.






42. Count++; count--






43. A value that is passed into a method when it is invoked






44. This declaration creates a Scanner object that reads input from the keyboard






45. 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






46. 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.






47. Expressed in a Java program with single quotes






48. They clarify the role a certain number has in the program.






49. Returns true if the scanner has anotehr token in its input.






50. ______________ operators have higher precedence