Skip to content

Commit 0b25dbb

Browse files
committed
Update lesson content
1 parent 78f8e15 commit 0b25dbb

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

SourceCode/chap_04-Operations/Lesson_01/ArithmeticOperators.java

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
/*****************************************************************************
22
* PROJECT: Java-101 Comprehensive Programming Course
33
* MODULE: Introduction to Java Fundamentals
4-
* LESSON: 2.1 - Arithmetic Operators
4+
* LESSON: 4.1 - Arithmetic Operators
55
*
66
* AUTHOR: Dr. Saad Laouadi, Ph.D.
77
* CREATED: March 2025
8+
* Updated: April 2025
89
*
910
* Copyright © 2025 Dr. Saad Laouadi. All Rights Reserved.
1011
* See LICENSE file for complete terms.
@@ -16,6 +17,7 @@ public static void main(String[] args) {
1617
int a = 10;
1718
int b = 3;
1819

20+
displayBanner('*', 62);
1921
System.out.println("ARITHMETIC OPERATORS DEMONSTRATION");
2022
System.out.println("==================================");
2123
System.out.println("Working with variables: a = " + a + ", b = " + b);
@@ -90,5 +92,12 @@ public static void main(String[] args) {
9092
System.out.println("\nOperator Precedence:");
9193
System.out.println(" 10 + 20 / 5 = " + (10 + 20 / 5) + " (division happens before addition)");
9294
System.out.println(" (10 + 20) / 5 = " + ((10 + 20) / 5) + " (parentheses override default precedence)");
95+
displayBanner('*', 62);
96+
}
97+
static void displayBanner(char c, int length){
98+
for (int i=0; i < length; i++){
99+
System.out.print(c);
100+
}
101+
System.out.println();
93102
}
94103
}

0 commit comments

Comments
 (0)