What Is a Question Mark in Java
Code? in Generic Code, the Question Mark (?), Called the Wildcard, Represents an Unknown Type. the Wildcard Can Be Used in a Variety of Situations: as the Type...
What is a question mark in Java code?
In generic code, the question mark (?), called the wildcard, represents an unknown type. The wildcard can be used in a variety of situations: as the type of a parameter, field, or local variable; sometimes as a return type (though it is better programming practice to be more specific).
Must Read
Does Java have question mark operator?
Conditional Expression Almost every operator has either one or two operands. This is the only operator in Java with three operands. This is called the conditional expression or the question mark-colon operator.