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. The one that is invoked






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






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






4. The values it stores internally - which may be represented as primitive data or as other objects. for example - a bank account object can store a floating point number (a primitive value) that represents the balance of the account. it can also contai






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






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






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






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






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






10. A Java operator that is specified by a type name in parentheses; truncates rather than rounds; useful in division if u want an integer to be treated as a float or double






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






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






13. Control access to the members of a class. the reserved words public and private are visibility modifiers that can be applied to the variables and methods of a class.






14. All wrapper classes are defined in ___________






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






16. Returns the character at the specified index.






17. An explicit data value used in a program






18. Expressed in a Java program with single quotes






19. Changes a particular value - e.g.setX - where X is the value they are setting.






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






21. Sets the scanner's delimiting pattern.






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






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






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






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






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






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






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






29. ______________ operators have higher precedence






30. Begins with a backslash character ""






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






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






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






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






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






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






37. A ________________ is immutable.






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






39. _____ expression evaluated first






40. Cast operator has _________ precedence to division






41. Instructs the compiler to reserve a portion of main memory space large enough to hold a particular type of value and indicates the name by which we refer to that location






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






43. Occurs when a value of one type is assigned to a variable of another type during which the value is converted to the new type.






44. Includes the type of teh return value - the method name - and the list of parameters that the method accepts.






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






46. Instance data should be defined with what________ visibility






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






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






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






50. Returns the number of characters in this stirng.