From b2ff0d101454f3e9d37fb840489d7d108608b2ec Mon Sep 17 00:00:00 2001 From: Jose De La Cruz Date: Thu, 28 May 2026 14:05:35 -0400 Subject: [PATCH] Completion of Variables.java --- .../_1_beginners/_1_thebasics/Variables.java | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/src/main/java/com/amigoscode/_1_beginners/_1_thebasics/Variables.java b/src/main/java/com/amigoscode/_1_beginners/_1_thebasics/Variables.java index 3d2ef3b..8402e0d 100644 --- a/src/main/java/com/amigoscode/_1_beginners/_1_thebasics/Variables.java +++ b/src/main/java/com/amigoscode/_1_beginners/_1_thebasics/Variables.java @@ -11,27 +11,33 @@ public class Variables { public static void main(String[] args) { // TODO: 1 - Declare an int variable called age and assign it the value 25 - + int age = 25; // TODO: 2 - Declare a double variable called price and assign it the value 9.99 - + double price = 9.99; // TODO: 3 - Declare a boolean variable called isJavaFun and assign it the value true - + boolean isJavaFun = true; // TODO: 4 - Declare a String variable called name and assign it your name - + String name = "Jose"; // TODO: 5 - Declare a char variable called grade and assign it the value 'A' - + char grade = 'A'; // TODO: 6 - Print all the variables above using System.out.println // Hint: You can print each variable on its own line, e.g.: // System.out.println("Age: " + age); - + System.out.println("Age: " + age); + System.out.println("Price: " + price); + System.out.println("isJavaFun: " + isJavaFun); + System.out.println("Name: " + name); + System.out.println("Grade: " + grade); // TODO: 7 - Declare a final (constant) variable called MAX_SCORE, set it to 100, and print it // Hint: Use the 'final' keyword before the type to make a constant + final int MAX_SCORE = 100; + System.out.println("MAX_SCORE: " + MAX_SCORE); } }