Declaring Variables Before using any variable, give it a name and data type. This is known as declaring a variable. The syntax for declaring a variable is [crayon-5ce67b4d9de26564150209/] or [crayon-5ce67b4d9de3b648001346/] Java objects stores states in fields. Java programming language defines the following kind of fields / variables. Local Variables Local variables are used to maintain