5 years ago in Java Generics

Which of the following reference types cannot be generic?

[A] Anonymous inner class
[B] Interface
[C] Inner class
[D] All of the mentioned
Loading...
Next Question

Overall Stats

Attempted 238
Correct 73
Incorrect 59
Viewed 106

Answers

Guest
Guest
David Naik
David Naik - 2 months ago

David Naik from India is saying Anonymous inner class is correct answer

Udit Sahu
Udit Sahu - 2 months ago

Udit Sahu is saying Anonymous inner class is correct answer

S SRIKANTH
S SRIKANTH - 3 months ago

S SRIKANTH is saying Interface is correct answer

Sathish Kumar R
Sathish Kumar R - 3 months ago

Sathish Kumar R is saying Interface is correct answer

Vedant Joshi
Vedant Joshi - 3 months ago

Vedant Joshi is saying Interface is correct answer

Related Questions

Which of these instance cannot be created?

  • [A] Integer instance.
  • [B] Generic class instance.
  • [C] Generic type instance.
  • [D] Collection instances.

Why are generics used?

  • [A] Generics make code more fast.
  • [B] Generics make code more optimised and readable.
  • [C] Generics add stability to your code by making more of your bugs detectable at compile time.
  • [D] Generics add stability to your code by making more of your bugs detectable at run time.

Which of these is an correct way of defining generic class?

  • [A] class name(T1, T2, …, Tn) { /* … */ }
  • [B] class name { /* … */ }
  • [C] class name[T1, T2, ..., Tn] { /* … */ }
  • [D] class name{T1, T2, …, Tn} { /* … */ }