(d) Write java statement to:
(i)declare a float variable.
(ii)declare a boolean variable.
(iii)declare a double variable and assign the result of the expression
12/3*2-1.
(iv)declare a char variable and assign 0 to it.
Answers
Answered by
0
Explanation:
(I) You can define a variable as a float and assign a value to it in a single declaration. For example: float age = 10.5; In this example, the variable named age would be defined as a float and assigned the value of 10.5.
Similar questions