
Program_3
Authored by Ms C
Engineering
Professional Development
Used 2+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
1. What is the purpose of the raiseSalary() method in the Employee class?
a) To set a new salary directly
b) To increase the salary by a given percentage
c) To print the salary details
d) To decrease the salary
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the access modifier for the instance variables id, name, and salary?
a) public
b) private
c) protected
d) default
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which keyword is used to create an object of the Employee class?
a) this
b) new
c) super
d) create
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which concept of OOP is shown by using private variables and public getter methods?
a) Inheritance
b) Encapsulation
c) Polymorphism
d) Abstraction
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What does the this keyword refer to inside the constructor?
a) The parent class
b) The current object of the class
c) The static variable
d) The superclass
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which method automatically executes when an object is printed?
a) print()
b) display()
c) toString()
d) show()
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which part of the program demonstrates data hiding?
a) Private variables with public getters
b) Printing salary
c) Using toString()
d) Using new keyword
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Similar Resources on Wayground
15 questions
AE01 Identification of Components and Circuits
Quiz
•
Professional Development
13 questions
GAS TURBINE
Quiz
•
Professional Development
15 questions
Defect Handling Quiz
Quiz
•
Professional Development
10 questions
Les bases de la planification
Quiz
•
Professional Development
10 questions
Tema 1.4 Dibujo Computarizado
Quiz
•
Professional Development
15 questions
RME Review - Forward Reverse Starters
Quiz
•
Professional Development
15 questions
BIT_QUIZ_Hadoop
Quiz
•
Professional Development
10 questions
THAY ĐỔI TUẦN 2 NGÀY 11.04
Quiz
•
Professional Development
Popular Resources on Wayground
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
22 questions
fractions
Quiz
•
3rd Grade
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
15 questions
Equivalent Fractions
Quiz
•
4th Grade
20 questions
Figurative Language Review
Quiz
•
6th Grade
Discover more resources for Engineering
10 questions
How to Email your Teacher
Quiz
•
Professional Development
6 questions
3RD GRADE DECLARATION OF INDEPENDENCE EXIT TICKET
Quiz
•
Professional Development
19 questions
Black History Month Trivia
Quiz
•
6th Grade - Professio...
22 questions
Multiplying Exponents with the Same Base
Quiz
•
9th Grade - Professio...
40 questions
Flags of the World
Quiz
•
KG - Professional Dev...