+923132835245
safcodeinstitute@gmail.com
Online Quiz
10000+ Questions!
Students Works
Ideas & Topics!
Live Coding
HTML & CSS
Home
(current)
About
Courses
CIT
Web Designing
Graphic Designing
Web Development
Digital Marketing
WordPress + SEO
Artificial Intelligence (AI)
Shopify + WordPress Development
Tutorials
Feedback
Programming Notes
Softwares
Contact
Test Your Programming Skills with Safcode!
Here is all important interview / exams questions.
Student doing practice apptitude test on safcode platform.
Instruction: "Total Number of Questions: 20
Each question carry 10 mark , no negative marking"
Quiz Start
1. Identify the shortest manner in which you can decorate a Java annotation
prefix #
prefix @
suflix @
suffix #
View Answer
2. A lambda expression facilitates __________
Logical programming
Functional programming
Backward reasoning
Structured programming
View Answer
3. Identify the number of times the @Repeatable annotation type can be executed on the same source code element by default.
Multiple
Zero
One
Twice
View Answer
4. The _____ class is declared without a name within a code block such as the body of a method.
None of these
Anonymous class
Local inner class
Final Class
View Answer
5. Which of the following methods cannot have a body in Java?
final
native
static
local
View Answer
6. Which of the following statement is true regarding local inner class.
None of these
Cannot access private members of the enclosing class
Can implement anonymous interfaces
Associated with an instance of the enclosing class
View Answer
7. In Java code, the line that begins with /* and ends with */ is known as?
Both A & B
Single line comment
Multiline comment
None of the above
View Answer
8. Which of the following annotations is used as custom annotation at runtime?
interface
@Documented
reference
@Retention
View Answer
9. Time-zone based date and time information of a ZonedDateTime object can be accessed using _______ method.
getValue()
of()
normalized()
instant()
View Answer
10. What are default methods also known as? a. Virtual extension methods b. Defender methods c. Extension methods
Only B
A and B
Only A
B and C
View Answer