logo

Crowdly

Browser

Add to Chrome

COMPSCI1018 Computing Science 1S - Computing Systems - 2024-25

Looking for COMPSCI1018 Computing Science 1S - Computing Systems - 2024-25 test answers and solutions? Browse our comprehensive collection of verified answers for COMPSCI1018 Computing Science 1S - Computing Systems - 2024-25 at moodle.gla.ac.uk.

Get instant access to accurate answers and detailed explanations for your course questions. Our community-driven platform helps students succeed!

Which instruction performs R5 := (*R4)?
0%
0%
0%
0%
View this question

Consider this program fragment:

i := 0;

sum := 0;

while i<n do

   { sum := sum + i;

     i := i + 1;

   }

a := sum;

Which of the following is a correct translation from high to low level?

0%
0%
View this question

Suppose R1 contains 00c6 and R2 contains 0dc1.

What is the effective address in this instruction?

lea  R2,8[R1]

Give the answer as a single hex word, with no $.

Example format of answer: f32b (four consecutive hex digits)

View this question
Which instruction adds 5 to register R2?
❌
✅
❌
❌
View this question
Which instruction puts a pointer to x into R3?
0%
0%
0%
0%
View this question

The variable p is a pointer to a record x. Which instruction puts p into R8?

0%
❌
View this question
When you are using a jump table, what could go wrong if the program

fails to check that the code is valid?

❌
✅
❌
View this question

What is the label of the instruction that will be executed

after the following code executes?

    lea R5,JT[R0]

    lea R4,3[R0]

    add R4,R4,R4

    add R4,R5,R4

    jump 0[R4]

JT  jump placeA[R0]

    jump placeB[R0]

    jump placeC[R0]

    jump placeD[R0]

    jump placeE[R0]

    jump placeF[R0]

placeG

0%
0%
0%
0%
0%
0%
0%
View this question
Suppose you have a code whose value is one of the following:

27, 192, 13, -4, 57, 83, 2, 941

For each value of the code there is a corresponding statement that

should be executed. Which technique should be used to implement this?

✅
❌
View this question
Suppose you have a code whose value is one of the following:

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15

For each value of the code there is a corresponding statement that

should be executed. Which technique should be used to implement this?

0%
0%
View this question

Want instant access to all verified answers on moodle.gla.ac.uk?

Get Unlimited Answers To Exam Questions - Install Crowdly Extension Now!

Browser

Add to Chrome