Chapter 2 Flashcards

1
Q

\n

A

New line (advances the cursor to the next line for subsequent printing)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

\t

A

Tab (cause the cursor to skip over to the next tab stop)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

\b

A

Backspace (causes the cursor to back up, or move left, one position

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

\r

A

Carriage return (causes the cursor to go to the beginning of the current line, not the next line)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

\

A

Backslash (causes a backslash to be printed)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

\’

A

Single quote (causes a single quotation mark to be printed)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

\”

A

Double quote (causes a double quotation mark to be printed)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Variable

A

Named storage location in the computers memory

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Literal

A

A value written into the code of a program

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Variable declaration

A

Tells compiler variable’s name and data type

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Primitive date types

A

Byte, short, int, long, char, boolean, float, double

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Highest rank data type

A

Double

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Second highest rank data type

A

Float

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Third highest data type

A

Long

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Fourth rank data type

A

Int

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

5th rank data type

A

Short

17
Q

Last data type

A

Byte

18
Q

Constant

A

Identifiers that can only hold a single value

19
Q

Importing JOptionPane

A

import javax.swing.JOptionPane;

20
Q

Message dialog

A

JOptionPane.showMessageDialog(null, “Hello World”);

21
Q

Input dialog

A

JOptionPane.showInputDialog(“your message or question.”);