
How to store Variables in Java?

public class DoubleTest {
public static void main(String[] args) {
double aDouble = 5.76; // Declare and initialize aDouble
System.out.println(aDouble); // Outputs 5.76
aDouble = 5.76 + 1.45;
System.out.println(aDouble); // Outputs 7.21
}
}
If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.
