Variables and Data Types in Java
In Java, you can declare variables to store values of various types. The data types supported by Java include int, double, boolean, char, String, and many more.
Example code:
arduino
int age = 25;
double height = 1.75;
boolean isMarried = false;
char gender = 'M';
String name = "John";
No comments:
Post a Comment