What is generics in java interview questions?
Answer / Nagender Kumar
"Generics in Java are a feature that allows you to create classes, interfaces, and methods that work with multiple data types. It helps to write more flexible and reusable code by allowing the same methods to work with different types. Type parameters are used to define the type of objects that can be used with a generic class or method."n
| Is This Answer Correct ? | 0 Yes | 0 No |
What are the different http methods?
Do I need to import java.lang package any time? Why?
what are class,constructor and primitive data types?
What is the use of static class?
How to Sort list of Strings in ascending order without using java api.
How many types of assembly languages are there?
Write a program to print 15 random numbers using foreach of java 8?
There is a Banking application. It has 2 types of account, Savings and Current. Write a method calculateInterest by passing an ArrayList of these account objects and calculate Interest accordingly. Write code for this situation
What if the main() method is declared as private? What happens when the static modifier is removed from the signature of the main() method?
What is difference between length and length() method in java ?
primitive data types in Java ?
What are the data types supported by java?