Classes and Objects Quiz

Description

Quiz on java classes and objects
ncmcoder
Quiz by ncmcoder, updated more than 1 year ago More Less
joannazhang13
Created by joannazhang13 over 9 years ago
ncmcoder
Copied by ncmcoder over 9 years ago
2
0
1 2 3 4 5 (0)

Resource summary

Question 1

Question
An object is characterized by:
Answer
  • State and Validity
  • Validity and Accessibility
  • State and Behavior
  • Behavior and Accessibility

Question 2

Question
A variable that represents an object is called
Answer
  • Conjugate
  • Abstract
  • Type
  • Object reference

Question 3

Question
State of a given object is maintained in its
Answer
  • Algorithms
  • Instance variables
  • Encapsulations
  • Behaviors

Question 4

Question
Combining an object's data and methods into a class is called
Answer
  • Encapsulation
  • Implementation
  • Inheritance
  • Boxing

Question 5

Question
Public methods are accessible to:
Answer
  • Some client programs
  • All client programs
  • All client programs that asks for return value
  • All client programs that are abstract

Question 6

Question
Static variables are shared by:
Answer
  • All instances of the class
  • All instances of the class that are private
  • All instances of the class that are public
  • Some instances of the class depending on what the static variable specifies.

Question 7

Question
A constructor
Answer
  • Must have arguments
  • Cannot be the same as the class
  • Creates and object of the class
  • Has a return type based on the class

Question 8

Question
Static methods
Answer
  • Must have a return type
  • Cannot access instance variables
  • Can access instance variables
  • Must not have a return type
Show full summary Hide full summary

0 comments

There are no comments, be the first and leave one below:

Similar

Input Devices
Jess Peason
Output Devices
Jess Peason
Networks
Will8324
General ICT Quiz
leahshaw
ICT Revison Flash Cards
Arun Johal
FLAT FILE VS RELATIONAL DATABASE
rosiejones
Online World - Learning Aim A
andysedge
Business Aims and ICT Strategies
scrt
User Interfaces
Skeletor
General ICT Quiz
Jade Fantom