0% found this document useful (0 votes)
0 views

3 - Elementary Programming 2_Data Types, Operators, Type Casting

Chapter 2 of 'Introduction to Java Programming' covers Java data types, operators, and input handling using the scanner class. It outlines the differences between primitive and non-primitive data types, explains how to read console input, and introduces various operator types. The chapter also emphasizes avoiding common programming errors and understanding conversion concepts.

Uploaded by

3slm3al
Copyright
© © All Rights Reserved
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
0 views

3 - Elementary Programming 2_Data Types, Operators, Type Casting

Chapter 2 of 'Introduction to Java Programming' covers Java data types, operators, and input handling using the scanner class. It outlines the differences between primitive and non-primitive data types, explains how to read console input, and introduces various operator types. The chapter also emphasizes avoiding common programming errors and understanding conversion concepts.

Uploaded by

3slm3al
Copyright
© © All Rights Reserved
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
You are on page 1/ 57

Chapter 2 Elementary Programming

Part (2)

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
1
Introduction
 Thislecture will cover Java data types, the
various operator types in Java, and how to
use the scanner class to obtain console
input. As a result, we will understand Java's
conversion concept and learn how to avoid
common errors in elementary programming.

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
2
Learning Objectives
1. Understand the concept of data types.
2. obtain input from the console using the scanner class.
3. Understand the Different types of Operators in Java
4. Understand the concept of conversion in Java.
5. Avoid common errors and pitfalls in elementary programming.

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
3
outlines
• Data Types
• Reading Input from the Console
• Java Operators
• Arithmetic Expressions
• Conversion Rules
• Common Errors and Pitfalls

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
4
Data Types
 As explained in the previous slides, a variable in
Java must be a specified data type:
 Data types are divided into two groups:
– Primitive data types - includes byte, short, int, long,
float, double, boolean and char
– Non-primitive data types - such as String, Arrays and
Classes (you will learn more about these in a later
chapter)

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
5
Primitive Data Types
 A primitive data type specifies the size and type of variable values, and it has no additional methods.

Data Type Size Description


Byte 1 byte Stores whole numbers from -128
to 127
Short 2 bytes Stores whole numbers from -
32,768 to 32,767
Int 4 bytes Stores whole numbers from -
2,147,483,648 to 2,147,483,647
Long 8 bytes Stores whole numbers from -
9,223,372,036,854,775,808 to
9,223,372,036,854,775,807

Float 4 bytes Store fractional numbers.


Sufficient for storing 6 to 7
decimal digits
Double 8bytes Store fractional numbers.
Sufficient for storing 15 decimal
digits
Boolean 1 bit Stores true or false values
char 2 bytes Stores a single character/letter
or ASCII values
Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
6
Numerical Data Types
 Primitive number types are divided into two groups:
 Integer types stores whole numbers, positive or negative (such as 123 or -456), without decimals. Valid types are byte, short, int and long. Which type you should
use, depends on the numeric value.
 Floating point types represents numbers with a fractional part, containing one or more decimals. There are two types: float and double.
 There are many numeric types in Java, the most used for numbers are:
 int (for whole numbers) and
 double (for floating point numbers).

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
7
Numerical Data Types
name range Storage Size
Byte -27to27 -1(-128to127) 8-bit signed
Short -215 to 215 - 1 (-32768 to 16-bit signed
32767)
Int -231 to 231 - 1 (-2147483648 to 32-bit signed
2147483647)

Long -263to263 -1 64-bit signed


(i.e., -9223372036854775808 to
9223372036854775807)

Float Negative range: -3.4028235E + 2-bit IEEE 754


38 to -1.4E - 45
Positive range: 1.4E - 45 to
3.4028235E + 38

double Negative range: - 64-bit IEEE 754


1.7976931348623157E + 308 to
-4.9E - 324
Positive range: 4.9E - 324 to
1.7976931348623157E + 308

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
8
Number Literals
A literal is a constant value that appears directly in the
program. For example, 34, 1,000,000, and 5.0 are literals
in the following statements:

int i = 34;
long x = 1000000L;
float f = 5.75f;
double d = 19.99d;

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
9
Integer Literals
An integer literal can be assigned to an integer variable as
long as it can fit into the variable. A compilation error
would occur if the literal were too large for the variable to
hold. For example, the statement byte b = 1000 would
cause a compilation error, because 1000 cannot be stored
in a variable of the byte type.
An integer literal is assumed to be of the int type, whose
value is between -231 (-2147483648) to 231–1
(2147483647). To denote an integer literal of the long
type, append it with the letter L or l. L is preferred because
l (lowercase L) can easily be confused with 1 (the digit
one).
Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
10
Floating-Point Literals
Floating-point literals are written with a decimal
point. By default, a floating-point literal is treated
as a double type value. For example, 5.0 is
considered a double value, not a float value. You
can make a number a float by appending the letter f
or F, and make a number a double by appending
the letter d or D. For example, you can use 100.2f
or 100.2F for a float number, and 100.2d or 100.2D
for a double number.

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
11
double vs. float
The precision of a floating point value indicates how many digits the value can have after
the decimal point. The precision of float is only six or seven decimal digits,
while double variables have a precision of about 15 digits. Therefore it is safer to
use double for most calculations.

System.out.println("1.0 / 3.0 is " + 1.0 / 3.0);


displays 1.0 / 3.0 is 0.3333333333333333
16 digits

System.out.println("1.0F / 3.0F is " + 1.0F / 3.0F);


displays 1.0F / 3.0F is 0.33333334
8 digits
Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
12
Scientific Numbers
 Floating-point literals can also be specified in scientific
notation, for example, 1.23456e+2, same as 1.23456e2, is
equivalent to 123.456, and 1.23456e-2 is equivalent to
0.0123456. E (or e) represents an exponent and it can be
either in lowercase or uppercase.

float f1 = 35e3f;
double d1 = 12E4d;

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
13
Data Type (Cont..)
 A Boolean data type is declared with the boolean keyword
and can only take the values true or false.
 The char data type is used to store a single character. The
character must be surrounded by single quotes, like 'A' or 'c'.
– Alternatively, you can use ASCII values to display certain
characters:
char a = 65, b = 66, c = 67;
 The String data type is used to store a sequence of characters
(text). String values must be surrounded by double quotes.

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
14
Non-Primitive Data Types
 Non-primitive data types are called reference types
because they refer to objects. The main difference
between primitive and non-primitive data types are:
– Primitive types are predefined (already defined) in Java.
Non-primitive types are created by the programmer and is
not defined by Java (except for String).
– Non-primitive types can be used to call methods to
perform certain operations, while primitive types cannot.

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
15
Non-Primitive Data Types (Cont..)
– A primitive type has always a value, while non-primitive
types can be null.
– A primitive type starts with a lowercase letter, while non-
primitive types starts with an uppercase letter.
– The size of a primitive type depends on the data type,
while non-primitive types have all the same size.

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
16
Exercise:
Add the correct data type for the following variables:

____myNum = 9;
____ myDoubleNum = 8.99;
____ myLetter = 'A';
____ myBool = false;
____ myText = "Hello World";

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
17
Reading Input from the Console
1. Create a Scanner object
Scanner input = new Scanner(System.in);

2. Use the method nextDouble() to obtain to a


double value. For example,
System.out.print("Enter a double value: ");
Scanner input = new Scanner(System.in);
double d = input.nextDouble();

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
18
Reading Numbers from the
Keyboard
Scanner input = new Scanner(System.in);
int value = input.nextInt();
method description
nextByte() Reads an integer of the byte type

nextShort() Reads an integer of the short type

nextInt() Reads an integer of the int type

nextLong() Reads an integer of the long type

nextFloat() Reads a number of the float type

nextDouble() Reads a number of the double type

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
19
Java Operators
 Operators are used to perform operations on
variables and values. Examples:
int x = 100 + 50;

int sum1 = 100 + 50; // 150 (100 + 50)


int sum2 = sum1 + 250; // 400 (150 + 250)
int sum3 = sum2 + sum2; // 800 (400 + 400)

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
20
Java Operators (Cont..)
 Java
divides the operators into the following
groups:
– Arithmetic operators
– Assignment operators
– Comparison operators
– Logical operators
– Bitwise operators

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
21
Arithmetic Operators
Operator Name Description Example

+ Addition Add together two values. x+y

– Subtraction Subtract one value from another x–y

* Multiplication Multiply two values. x*y

/ Division Divide one value by another. x/y

% Modulus Returns the division remainder x%y

++ Increment Increases the value of a variable by 1 ++x

-- Decrement Decreases the value of a variable by 1 --x

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
22
Integer Division

5 / 2 yields an integer 2.
5.0 / 2 yields a double value 2.5

5 % 2 yields 1 (the remainder of the division)

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
23
Remainder Operator
Remainder is very useful in programming. For example, an
even number % 2 is always 0 and an odd number % 2 is always
1. So you can use this property to determine whether a number
is even or odd. Suppose today is Saturday and you and your
friends are going to meet in 10 days. What day is in 10
days? You can find that day is Tuesday using the following
expression:

Saturday is 6th day in a week


A week has 7 days
(6 + 10) % 7 is 2
The 2nd day in a week is Tuesday
After 10 days

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
24
Increment and
Decrement Operators
Operator name Description Example (assume i = 1)
++var preincrement Increment var by 1, and int j = ++i;
use the new var value in // j is 2, i is 2
the statement
var++ postincrement Increment var by 1, but int j = i++;
use the // j is 1, i is 2
original var value in the
statement
--var predecrement Decrement var by 1, and int j = --i;
use the new var value in // j is 0, i is 0
the statement

Var-- postdecrement Decrement var by 1, and int j = i --;


use the // j is 1, i is 0
original var value in the
statement

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
25
Increment and
Decrement Operators (Cont..)

int i = 10; Same effect as int newNum = 10 * i;


int newNum = 10 * i++;
i = i + 1;

int i = 10;
int newNum = 10 * (++i); Same effect as i = i + 1;
int newNum = 10 * i;

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
26
Increment and
Decrement Operators (Cont..)
Using increment and decrement operators makes
expressions short, but it also makes them complex and
difficult to read. Avoid using these operators in expressions
that modify multiple variables, or the same variable for
multiple times such as this: int k = ++i + i.

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
27
Java Assignment Operators
 Assignment operators are used to assign values to
variables. In the example below, we use the
assignment operator (=) to assign the value 10 to a
variable called x: int x = 10;

 The addition assignment operator (+=) adds a value


to a variable:
int x = 10;
x += 5;

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
28
Java Assignment Operators
(Cont..)
Operator Example Same as
= X=5 X=5
+= X += 3 X=x+3
-= X -= 3 X= x - 3
*= X *= 3 X=x*3
/= X /= 3 X= x/3
%= X %= 3 X=x%3
&= X &= 3 X= x & 3
|= X|=3 X = x |3
^= X ^= 3 X=x^3
>>= X >> = 3 X = x >> 3
<<= X << =3 X = x << 3
Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
29
Java Comparison Operators
 Comparison operators are used to compare two values:
Operator Name example

== equal to X == y

!= not equal to X != y

> greater than X>y

< less than X<y

>= greater than or equal to X >= y

<= less than or equal to X <=y

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
30
Java Logical Operators

Operator Name Description example


&& Logical and Returns true if both X < 5 && x < 10
statements are true
| Logical or Returns true if one of X < 5 | | x < 4
the statements is true

! Logical not Reverse the result , !(X < 5 && x < 10)
returns false if the
result is true

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
31
Exercise:

Multiply 10 with 5, and print the result:


System.out.println (10 5);

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
32
Problem: Displaying Time
Write a program that obtains minutes and
remaining seconds from seconds.

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
33
NOTE
Calculations involving floating-point numbers are
approximated because these numbers are not stored
with complete accuracy. For example,
System.out.println(1.0 - 0.1 - 0.1 - 0.1 - 0.1 - 0.1);
displays 0.5000000000000001, not 0.5, and
System.out.println(1.0 - 0.9);
displays 0.09999999999999998, not 0.1. Integers are
stored precisely. Therefore, calculations with integers
yield a precise integer result.
Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
34
Exponent Operations
System.out.println(Math.pow(2, 3));
// Displays 8.0
System.out.println(Math.pow(4, 0.5));
// Displays 2.0
System.out.println(Math.pow(2.5, 2));
// Displays 6.25
System.out.println(Math.pow(2.5, -2));
// Displays 0.16

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
35
Arithmetic Expressions

is translated to

(3+4*x)/5 – 10*(y-5)*(a+b+c)/x + 9*(4/x + (9+x)/y)

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
36
How to Evaluate an Expression
Though Java has its own way to evaluate an
expression behind the scene, the result of a Java
expression and its corresponding arithmetic
expression are the same. Therefore, you can safely
apply the arithmetic rule for evaluating a Java
expression. 3 + 4 * 4 + 5 * (4 + 3) - 1 (1) inside parentheses first
3+4*4+5*7–1
(2) Multiplication
3 + 16 + 5 * 7 – 1
(3) Multiplication
3 + 16 + 35 – 1
(4) Addition
19 + 35 – 1
(5) Addition
54 – 1
(6) subtraction
53
Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
37
Problem: Converting Temperatures
Write a program that converts a Fahrenheit degree
to Celsius using the formula:
celsius ( 95 )( fahrenheit  32)

Note: you have to write


celsius = (5.0 / 9) * (fahrenheit – 32)

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
38
Problem: Displaying Current Time
Write a program that displays current time in GMT in the
format hour:minute:second such as 1:45:19.
The currentTimeMillis method in the System class returns
the current time in milliseconds since the midnight, January
1, 1970 GMT. (1970 was the year when the Unix operating
system was formally introduced.) You can use this method
to obtain the current time, and then compute the current
second, minute, and hour as follows.
Elapsed
time
time
Unix Epoch
01-01-1970 Current Time
00:00:00 GMT System.currentTimeMills()

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
39
Numeric Type Conversion
Consider the following statements:

byte i = 100;
long k = i * 3 + 4;
double d = i * 3.1 + k / 2;

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
40
Conversion Rules
When performing a binary operation involving two
operands of different types, Java automatically
converts the operand based on the following rules:

1. If one of the operands is double, the other is


converted into double.
2. Otherwise, if one of the operands is float, the other is
converted into float.
3. Otherwise, if one of the operands is long, the other is
converted into long.
4. Otherwise, both operands are converted into int.

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
41
Type Casting
 Type casting is when you assign a value of one primitive data
type to another type.
 In Java, there are two types of casting:
– Widening Casting (automatically) - converting a smaller type to a larger type
size
 byte -> short -> char -> int -> long -> float -> double

– Narrowing Casting (manually) - converting a larger type to a smaller size


type
 double -> float -> long -> int -> char -> short -> byte

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
42
Type Casting
Implicit casting (done automatically)
double d = 3; (type widening)

Explicit casting (done manually)


int i = (int)3.0; (type narrowing)
int i = (int)3.9; (Fraction part is truncated)

What is wrong? int x = 5 / 2.0;

range increases

byte, short, int, long, float, double

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
43
Widening Casting
Widening casting is done automatically when passing a
smaller size type to a larger size type:
int myInt = 9;

// Automatic casting: int to double


double myDouble = myInt;

System.out.println(myInt); //Outputs 9 System.out.println(myDouble); //Outputs 9.0

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
44
Narrowing Casting
Narrowing casting must be done manually by placing the
type in parentheses in front of the value:
double myDouble = 9.78d;

// Manual casting: double to int


int myInt = (int) myDouble;

System.out.println(myDouble); //Outputs 9.78 System.out.println(myInt); //Outputs 9

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
45
Problem: Keeping Two Digits After
Decimal Points
Write a program that displays the sales tax with two
digits after the decimal point.

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
46
Casting in an Augmented Expression
In Java, an augmented expression of the form x1 op=
x2 is implemented as x1 = (T)(x1 op x2), where T is
the type for x1. Therefore, the following code is
correct.
int sum = 0;
sum += 4.5; // sum becomes 4 after this statement

sum += 4.5 is equivalent to sum = (int)(sum + 4.5).


Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
47
Problem:
Computing Loan Payments
This program lets the user enter the interest
rate, number of years, and loan amount, and
computes monthly payment and total
payment.

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
48
Problem: Monetary Units

This program lets the user enter the amount in


decimal representing dollars and cents and output
a report listing the monetary equivalent in single
dollars, quarters, dimes, nickels, and pennies.
Your program should report maximum number of
dollars, then the maximum number of quarters,
and so on, in this order.

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
49
Common Errors and Pitfalls
 Common Error 1: Undeclared/Uninitialized
Variables and Unused Variables
 Common Error 2: Integer Overflow
 Common Error 3: Round-off Errors
 Common Error 4: Unintended Integer Division
 Common Error 5: Redundant Input Objects

 Common Pitfall 1: Redundant Input Objects


Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
50
Common Error 1:
Undeclared/Uninitialized Variables
and Unused Variables
double interestRate = 0.05;
double interest = interestrate * 45;

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
51
Common Error 2: Integer Overflow

int value = 2147483647 + 1;


// value will actually be -2147483648

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
52
Common Error 3: Round-off Errors

System.out.println(1.0 - 0.1 - 0.1 - 0.1 - 0.1 - 0.1);

System.out.println(1.0 - 0.9);

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
53
Common Error 4: Unintended Integer
Division
int number1 = 1; int number1 = 1;
int number2 = 2; int number2 = 2;
double average = (number1 + number2) / 2; double average = (number1 + number2) / 2.0;
System.out.println(average); System.out.println(average);

(a) (b)

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
54
Common Pitfall 1: Redundant Input
Objects
Scanner input = new Scanner(System.in);
System.out.print("Enter an integer: ");
int v1 = input.nextInt();

Scanner input1 = new Scanner(System.in);


System.out.print("Enter a double value: ");
double v2 = input1.nextDouble();
Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
55
Lecture Summary

 Understanding Data Types in Java


 Obtaining console input using scanner class.
 Different types of Operators in Java.
 Understanding conversion concept in Java.
 Avoiding common errors in elementary programming.

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
56
References
 Y. Daniel Liang, 2019, Intro to Java Programming, Comprehensive Version, Student Value Edition
12th Edition. Pearson, ISBN-10 : 0136520154 ISBN-13: 978-0136520153.

 Introduction to Java, https://www.w3schools.com/java/java_intro.asp, Last Updated 2024, Last


Accessed March 2024

Liang, Introduction to Java Programming, Tenth Edition, (c) 2015 Pearson Education, Inc. All
rights reserved.
57

You might also like