Question: Suggest a suitable Java data type that can be used to store each of the following values: i) Name of a person, for example: Johnson

Suggest a suitable Java data type that can be used to store each of the following values: i) Name of a person, for example: Johnson ii) Gender of a person, for example: F iii) An indicator to identify whether a transaction is successful, for example: true iv) Cost of an item, for example: 8.50 v) Number of students in a class, for example: 35 State whether the following statements are true or false. For false statements, explain why. i) The default case is required in the switch selection structure ii) The break statement is always required in the default case of a switch selection structure iii) Switch statements cannot test for a range of values
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
