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. Modifier>type/void>identifier>parameters>method body






2. Elements of input






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






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






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






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






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






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






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






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






11. We use an object when we have a _________ to it






12. Behaviors associated with a bank account (which include the ability to make deposits and withdrawals)






13. A name for a location in memory used to hold a data value.






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






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






16. Since an object ref var holds the address of the object - it can be thought of as a ____ to the location in memory where the object is held






17. A combo of one or more operators and operands that usually perform a calculation; operands can be literals - constants - variables - or other sources of data






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






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






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






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






22. Specifies the packages and classes that will be used in a program so that the fully qualified name is not necessary with each reference.






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






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






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






26. A variable that refers to an object must be __________






27. Begins with a backslash character ""






28. White space characters such as space characters - tabs - and new lines that separate the elements of input






29. Variables that don't contain any data






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






31. An object has behaviors - which are defined by the ________ associated with that object.






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






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 the next input token as the indicated type.






35. Delimited by double quotation characters






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






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






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






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






40. Two floating data types: float - _______






41. Returns an integer indicating if this string is lexically before - equal to - or lexically after the string str.






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






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






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






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






46. Constructors do not even _______; therefore they cannot return a value.






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






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






49. Even though a method may not take parameters - _________ are still necessary to indicate that a method is being invoked






50. A method that returns a value must have a _________