Exam prep Flashcards

1
Q

What happens if a signed and unsigned value are used in an expression?

A

The signed value is converted to an unsigned value

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

What happens first when changing size and sign?

A

Size changes first

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

How many times the bits do you need for multiplication?

A

2 times

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

How many bits are required for two’s complement multiplication?

A

2W bits

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

What are system directories surrounded by?

A

<>

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

What are user directories surrounded by?

A

“ “

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

Does a=b=c=4 set all values to 4?

A

Yes

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

Can global variables be assigned other variables?

A

No

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

If a type is not specified, what is it assumed to be?

A

Int

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

What are syntactic errors?

A

When the input code is not legal and is caught by the compiler

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

What are semantic errors?

A

When the code is legal but not what the programmer intended and is not caught by the compiler

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

What are algorithmic errors?

A

Problems with the logic of the program—does what the programmer intended but doesn’t solve the right problem.

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