Ch.3 Flashcards

1
Q

integer

A

Whole number

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

real

A

Real numbers

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

char

A

Characters

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

string

A

A sequence of characters,up to 255 characters

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

boolean

A

Logical value(TRUE or FALSE)

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

:

A

Declarations of a variable

var 〈variable〉:〈data type〉

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

=

A

Declaration of a constant
(Also used for comparing two values.)
const 〈constant name 〉= 〈value〉;

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

:=

A

Assignment of a value to a variable

〈variable〉 :=〈value〉 ;

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

Are spaces allowed in names?

A

No

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

div

A

Integer division
e.g. a := 17 div 3;
a=5

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

mod

A

Modulo (remainder)
e.g. a := 17 mod 3;
a=2

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

What is the difference between variable and constant?

A

Constants can’t be changed which the value are assigned to them while variables can be assigned in the later stage .

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