Java Programming - Chapter 2

अब Quizwiz के साथ अपने होमवर्क और परीक्षाओं को एस करें!

String

a built-in Java class that provides you with the means for storing and manipulating character strings

lossy conversion

a conversion in which some data is lost

lossless conversion

a conversion is one in which no data is lost

float

a data type that can hold a floating-point value of up to six or seven significant digits of accuracy

char

a data type used to hold any single character

scientific notation

a display format that more conveniently expressed large or small numeric values; a multidigit number is converted to a single-digit number and multiplied by 10 to a power

blank final

a final variable that has not yet been assigned a value

prompt

a message that requests and describes user input

symbolic constant

a named constant

variable

a named memory location that you can use to store a value

named constant

a named memory location whose assigned value cannot change during program execution

floating-point

a number that contains decimal positions

numeric constant

a number whose value is taken literally at each use

primitive type

a simple data type, in Java they are: byte, short, int, long, float, double, char, and boolean

unifying type

a single data type to which all operands in an expression are converted

keyboard buffer

a small area of memory where keystrokes are stored before they are retrieved into a program

variable declaration

a statement that reserves a named memory location

camel casing

a style in which an identifier begins with a lowercase letter and subsequent words within the identifier are capitalized

token

a unit of data separated with whitespace

magic number

a value that does not have immediate, intuitive meaning or a number that cannot be explained without additional knowledge - Unnamed constants are magic numbers.

literal constant

a value that is taken literally at each use

integer

a whole number without decimal places

mod

an abbreviation for the modulus operator and is an alternate name for the remainder operator

initialization

an assignment made when you declare a variable

null String

an empty String created by typing a set of quotes with nothing between them

lvalue

an expression that can appear on the left side of an assignment statement

rvalue

an expression that can appear only on the right side of an assignment statement

data type

an item's data type describes the type of data that can be stored there, how much memory the item occupies, and what types of operations can be performed on the data

comparison operator

another name for a relational operator

reference types

complex data types that are constructed from primitive types

constant

describes a value that cannot be changed during the execution of an application

concatenated

describes values that are attached end to end

promotions

implicit conversions

strongly typed language

one in which each variable has a well-defined type that limits the operations you can perform with it; strong typing implies that variables must be declared before they can be used

uninitialized variable

one that has not been assigned a value

significant digits

refers to the mathematical accuracy of a value

Associativity

refers to the order in which operands are used with operators

double-precision floating-point number

stored in a double

assignment

the act of providing a value for a variable

scope

the area in which a data item is visible to a program and in which you can refer to it using its simple identifier

implicit conversion

the automatic transformation of one data type to another

block of code

the code contained between a set of curly braces

assignment operator

the equal sign (=); any value to the right of the equal sign is assigned to the variable on the left of the equal sign

type-ahead buffer

the keyboard buffer

Integer division

the operation in which two values are divided and both are integers; the result contains no fractional part

remainder operator

the percent sign; when it is used with two integers, the result is an integer with the value of the remainder after division takes place

type conversion

the process of converting one data type to another

Operator precedence

the rules for the order in which parts of a mathematical expression are evaluated

garbage value

the unknown value stored in an uninitialized variable

type-wrapper classes

these are contained in the java.lang package and include methods that can process primitive type values

standard arithmetic operators

these are used to perform calculations with values

binary operators

these require two operands

input dialog box

this asks a question and provides a text field in which the user can enter a response

escape sequence

this begins with a backslash followed by a character; the pair represents a single character

relational operator

this compares two items; an expression that contains a relational operator has a Boolean value

double

this data type can hold a floating-point value of up to 14 or 15 significant digits of accuracy

short

this data type holds small integers, from -32,768 to 32,767

long

this data type holds very large integers, from -9,223,372,036,854,775,808 to 9,223,372,036,854,775,807

byte

this data type holds very small integers, from -128 to 127

int

this data type is used to declare variables and constants that store integers in the range of -2,147,483,648 to +2,147,483,647

confirm dialog box

this displays the options Yes, No, and Cancel

Type casting

this forces a value of one data type to be used as a value of another type

unnamed constant

this has no identifier associated with it

unary cast operator

this is a more complete name for the cast operator that performs explicit conversions

operand

this is a value used in an arithmetic statement

Promotion

this is an implicit conversion

standard input device

this is normally the keyboard

modulus operator

this is sometimes abbreviated as mod and is an alternate name for the remainder operator

single-precision floating-point number

this is stored in a float

explicit conversion

this is the data type transformation caused using a cast operator

Floating-point division

this is the operation in which two values are divided and either or both are floating-point values

final

this keyword precedes named constant declarations

Echoing the input

this means to repeat the user's entry as output so the user can visually confirm the entry's accuracy

cast operator

this performs an explicit type conversion; it is created by placing the desired result type in parentheses before the expression to be converted

null

this type of String is an empty String created by typing a set of quotes with nothing between them

unary operator

this uses only one operand

boolean variable

this variable can hold only one of two values - true or false

parse

to break into component parts

consume

to retrieve and discard an entry without using it

consume

to retrieve and discard it without using it


संबंधित स्टडी सेट्स

EXPH 2045 Exam 1 - Homeostasis/Skeletal

View Set

Intro To Computing - Python 3 Pt 2

View Set

Exercise 7: chemically defined, complex, selective, and differential media

View Set

The Reproductive System - Chapter 28

View Set

chapter 32- hypertension-hypertension

View Set

D5 Protection of Information Assets 5/31/2017

View Set

Chapter 26: Disorders of Blood Flow and Blood Pressure Regulation

View Set

Science Chapter 16 : Surface Waters

View Set

Click Restraint: Crash Course Navigating Digital Information #9

View Set

SIE unit 5 - Other Investment Vehicles

View Set