Cognizant interview question

Very basic java definitions.