InterviewSolution
Saved Bookmarks
| 1. |
Which of these is an correct way of defining generic method?(a) name(T1, T2, …, Tn) { /* … */ }(b) public name { /* … */ }(c) class name[T1, T2, …, Tn] { /* … */ }(d) name{T1, T2, …, Tn} { /* … */ }I have been asked this question in an internship interview.The question is from Generic Methods topic in portion Generics of Java |
|
Answer» The correct option is (b) public |
|