package JAVA;
public class Assignment3 {
public static void main(String[] args) {
// Variable to store the sum, initialized to 0
int sum = 0;
// Variable to represent multiples of 5, initialized to 5
int multiple = 5;
// Counter for the loop, initialized to 0
int count = 0;
// Print the first number in the sum expression
System.out.print("5");
// Loop while the count is less than 9999
while (count < 9999) {
// Get the next multiple of 5
multiple += 5;
// Print the current multiple with a plus sign for the sum expression
System.out.print("+" + multiple);
// Add the current multiple to the sum
sum += multiple;
// Increment the loop counter
count++;
}
// Print the equal sign and the final sum
System.out.println("=" + sum);
}
}