Coa Cse D: Quiz 2

Approved & Edited by ProProfs Editorial Team
The editorial team at ProProfs Quizzes consists of a select group of subject experts, trivia writers, and quiz masters who have authored over 10,000 quizzes taken by more than 100 million users. This team includes our in-house seasoned quiz moderators and subject matter experts. Our editorial experts, spread across the world, are rigorously trained using our comprehensive guidelines to ensure that you receive the highest quality quizzes.
Learn about Our Editorial Process
| By Rahul
R
Rahul
Community Contributor
Quizzes Created: 1 | Total Attempts: 105
Questions: 24 | Attempts: 105

SettingsSettingsSettings
Computer Quizzes & Trivia

.


Questions and Answers
  • 1. 

    In case of, Zero-address instruction method the operands are stored in _____

    • A.

      Registers

    • B.

      Accumulators

    • C.

      Push down stack

    • D.

      Cache

    Correct Answer
    C. Push down stack
    Explanation
    In the zero-address instruction method, the operands are stored in a push down stack. This means that the operands are pushed onto the top of the stack and can be accessed later when needed. This method allows for efficient storage and retrieval of operands, as well as flexibility in the order of operations.

    Rate this question:

  • 2. 

    In assembly language programming, minimum number of operands required for an instruction is/are

    • A.

      Zero

    • B.

      One

    • C.

      Two

    • D.

      Both C and D

    Correct Answer
    A. Zero
    Explanation
    In assembly language programming, the minimum number of operands required for an instruction is zero. This means that there are instructions that do not require any operands to perform their operation. These instructions are typically used for simple operations or for instructions that do not require any input or output.

    Rate this question:

  • 3. 

    In which addressing mode the operand is given explicitly in the instruction?

    • A.

      Absolute

    • B.

      Immediate

    • C.

      Indirect

    • D.

      Direct

    Correct Answer
    B. Immediate
    Explanation
    Immediate addressing mode is the addressing mode in which the operand is given explicitly in the instruction. This means that the value of the operand is directly specified in the instruction itself, rather than being stored in a memory location or calculated using an expression. Immediate addressing mode is commonly used for constants or immediate values that need to be used in arithmetic or logical operations.

    Rate this question:

  • 4. 

    In the following indexed addressing mode instruction, MOV 5(R1),LOC, the effective address is ______

    • A.

      EA = 5+R1

    • B.

      EA = R1

    • C.

      EA = [R1]

    • D.

      EA = 5+[R1]

    Correct Answer
    D. EA = 5+[R1]
    Explanation
    The given instruction MOV 5(R1),LOC uses indexed addressing mode. In this mode, the effective address is calculated by adding the displacement value (5) to the value stored in the register R1. Therefore, the effective address is EA = 5 + [R1].

    Rate this question:

  • 5. 

    If a system is 64 bit machine , then the length of each word will be _______

    • A.

      4 Byte

    • B.

      8 Byte

    • C.

      12 Byte

    • D.

      16 Byte

    Correct Answer
    B. 8 Byte
    Explanation
    In a 64-bit machine, the length of each word is typically 8 bytes. This is because a 64-bit machine has a 64-bit processor, which means it can handle data in 64-bit chunks or words. Each word consists of 8 bytes, where each byte is 8 bits. This allows the processor to process larger amounts of data at a time, resulting in improved performance and efficiency compared to a 32-bit machine.

    Rate this question:

  • 6. 

    When using the Big Endian assignment to store a number, the sign bit of the number is stored in _____

    • A.

      The higher order byte of the word

    • B.

      The lower order byte of the word

    • C.

      Can’t say

    • D.

      None of the mentioned

    Correct Answer
    A. The higher order byte of the word
    Explanation
    In Big Endian assignment, the most significant byte of a word is stored in the higher order byte position. Since the sign bit of a number is typically located in the most significant bit of a byte, it follows that the sign bit of the number will be stored in the higher order byte of the word.

    Rate this question:

  • 7. 

    A _______ gate is used to detect the occurrence of an overflow.

    • A.

      NAND

    • B.

      XOR

    • C.

      XNOR

    • D.

      AND

    Correct Answer
    B. XOR
    Explanation
    An XOR gate is used to detect the occurrence of an overflow because it produces a high output only when the number of high inputs is odd. In the case of detecting an overflow, an XOR gate can be used to compare the carry-out from the most significant bit (MSB) with the carry-in to the MSB. If the two inputs are different, indicating an overflow, the XOR gate will output a high signal.

    Rate this question:

  • 8. 

    In a normal adder circuit the delay obtained in generation of the output is _______

    • A.

      2n + 2

    • B.

      2n

    • C.

      n + 2

    • D.

      None of the mentioned

    Correct Answer
    A. 2n + 2
    Explanation
    In a normal adder circuit, the delay obtained in the generation of the output is 2n + 2. This means that for an n-bit adder, there will be a delay of 2n + 2 time units before the output is generated. The delay is determined by the number of stages in the adder circuit, which is equal to the number of bits in the input. Each stage introduces a delay of 1 time unit, and there are 2n stages in total. Additionally, there are 2 extra time units for the carry propagation and final output generation. Therefore, the total delay is 2n + 2.

    Rate this question:

  • 9. 

    A subtractor is not usually present in a computer because

    • A.

      It is expensive

    • B.

      It is not possible to design it

    • C.

      The full adder will take care of subtraction

    • D.

      None of these

    Correct Answer
    C. The full adder will take care of subtraction
    Explanation
    A subtractor is not usually present in a computer because the full adder can perform both addition and subtraction operations. The full adder has the capability to subtract by using the concept of two's complement, which allows for efficient subtraction without the need for a separate subtractor circuit. Therefore, there is no need to include a separate subtractor in a computer system.

    Rate this question:

  • 10. 

    Which condition code register flags will be set to 1 when result is negative?

    • A.

      N

    • B.

      Z

    • C.

      V

    • D.

      C

    Correct Answer
    A. N
    Explanation
    The condition code register flag N will be set to 1 when the result is negative. This flag indicates that the result of an operation is negative, meaning that the most significant bit of the result is 1.

    Rate this question:

  • 11. 

    The 32 bit number 5A938AF2 is held in (Byte Addressed) memory using the big-endian method starting at location 100.The number held in memory location 102 is

    • A.

      1100 0011

    • B.

      1000 1010

    • C.

      1000 0011

    • D.

      1100 0111

    Correct Answer
    B. 1000 1010
    Explanation
    The given memory layout represents a big-endian method, where the most significant byte is stored at the lowest memory address. Since the number is 32 bits long, it is stored across four memory locations starting from location 100. The number held in memory location 102 corresponds to the second byte of the 32-bit number, which is "1000 1010" in binary. Therefore, the correct answer is "1000 1010".

    Rate this question:

  • 12. 

    The words are said to be ______ in memory if they begin at a byte address that is multiple of number of bytes in a word

    • A.

      Aligned

    • B.

      Unaligned

    • C.

      Byte Addressable

    • D.

      Memory words

    Correct Answer
    A. Aligned
    Explanation
    In computer memory, words are considered to be aligned if they start at a byte address that is a multiple of the number of bytes in a word. This means that the starting address of the word is evenly divisible by the word size. Aligned memory access is important for efficient data retrieval and manipulation, as unaligned access can result in performance penalties or even errors. Therefore, the correct answer is "Aligned."

    Rate this question:

  • 13. 

    The 64 bit number A526FFAD4AC38BF2X is held in (Byte Addressed) memory using the big-endian method starting at location 100.The number held in memory location 105 is transferred to Register R1 . What would be the binary contents of R1 ?

    • A.

      1100 0011

    • B.

      1100 0010

    • C.

      1000 0011

    • D.

      1100 0111

    Correct Answer
    A. 1100 0011
    Explanation
    The binary contents of R1 would be 1100 0011 because the number held in memory location 105 is transferred to R1.

    Rate this question:

  • 14. 

    The instruction, Add #45,R1 does

    • A.

      Adds the value of 45 to the address of R1 and stores 45 in that address

    • B.

      Adds 45 to the value of R1 and stores it in R1

    • C.

      Finds the memory location 45 and adds that content to that of R1

    • D.

      None of these

    Correct Answer
    B. Adds 45 to the value of R1 and stores it in R1
    Explanation
    The instruction "Add #45, R1" indicates that the value of 45 should be added to the current value stored in register R1. After performing the addition, the result is stored back in register R1. This means that the value of R1 is updated by adding 45 to its previous value.

    Rate this question:

  • 15. 

    Consider the byte register R1 = ABH . What will be contents of R1 after the execution of AShiftL #2, R1?

    • A.

      EA

    • B.

      2B

    • C.

      A3

    • D.

      F5

    Correct Answer
    A. EA
    Explanation
    The contents of register R1 after the execution of AShiftL #2, R1 will be EA. The AShiftL instruction performs a logical left shift operation on the value in R1 by a specified number of bits. In this case, the value in R1 (ABH) will be shifted to the left by 2 bits, resulting in EAH. Therefore, the contents of R1 after the execution will be EA.

    Rate this question:

  • 16. 

    Which condition code register flags will be tested by Branch > 0 instruction?

    • A.

      Zero

    • B.

      Overflow

    • C.

      Zero and carry

    • D.

      Zero and negative

    Correct Answer
    D. Zero and negative
    Explanation
    The Branch > 0 instruction will test the zero and negative condition code register flags. The zero flag indicates whether the result of the previous operation was zero, while the negative flag indicates whether the result was negative. By testing these flags, the instruction can determine whether the branch should be taken based on whether the previous operation resulted in a zero or negative value.

    Rate this question:

  • 17. 

    Addressing mode used in instruction Add r1,r2,r3 is______

    • A.

      Registers

    • B.

      Index addressing mode

    • C.

      Indirect addressing mode

    • D.

      Offset addressing mode

    Correct Answer
    A. Registers
    Explanation
    The given instruction "Add r1,r2,r3" uses the addressing mode of Registers. In this mode, the operands of the instruction are directly specified using registers. In this case, the values in registers r2 and r3 are added together and the result is stored in register r1. This mode is commonly used for arithmetic operations where the operands are stored in registers.

    Rate this question:

  • 18. 

    Match each of the high level language statements given on the left hand side with the most natural addressing mode from those listed on the right hand side. 1. A[1] = B[J]; a. Indirect addressing 2. while [*A++]; b. Indexed addressing 3. int temp = *x; c. Autoincrement

    • A.

      (1, c), (2, b), (3, a)

    • B.

       (1, a), (2, c), (3, b)

    • C.

      (1, b), (2, c), (3, a)

    • D.

      (1, a), (2, b), (3, c)

    Correct Answer
    C. (1, b), (2, c), (3, a)
    Explanation
    The correct answer is (1, b), (2, c), (3, a).

    In statement 1, A[1] = B[J], the most natural addressing mode is indexed addressing because it involves accessing an element in an array (A) using an index (1) and another array (B) using a variable (J).

    In statement 2, while [*A++], the most natural addressing mode is autoincrement because it involves accessing the value pointed to by a pointer (A) and then incrementing the pointer.

    In statement 3, int temp = *x, the most natural addressing mode is indirect addressing because it involves accessing the value pointed to by a pointer (x).

    Rate this question:

  • 19. 

    The instruction ADD R1, 30FF is of _____

    • A.

      A 3-address instruction format

    • B.

      A 2-address instruction format

    • C.

      A 1-address instruction format

    • D.

      A 0-address instruction format

    Correct Answer
    B. A 2-address instruction format
    Explanation
    The instruction ADD R1, 30FF is of a 2-address instruction format. In this format, the instruction specifies both the source and destination operands within the instruction itself. In this case, the source operand is the value stored at memory address 30FF, and the destination operand is the register R1. The instruction will add the value at memory address 30FF to the value in register R1.

    Rate this question:

  • 20. 

    Displacement addressing mode will have example

    • A.

      Add R4,R3

    • B.

      Add R4,#3

    • C.

      Add R4,100(R1)

    • D.

      Add R3,(R1 + R2)

    Correct Answer
    C. Add R4,100(R1)
    Explanation
    The correct answer is "Add R4,100(R1)" because this instruction uses the displacement addressing mode. In this mode, the effective address is calculated by adding the displacement value (100) to the contents of register R1. This allows the program to access memory locations that are located at a fixed distance from the base address stored in R1.

    Rate this question:

  • 21. 

    When using the Little Endian assignment to store a number, the sign bit of the number is stored in _____

    • A.

      The higher order byte of the word

    • B.

      The lower order byte of the word

    • C.

      Can’t say

    • D.

      None of the mentioned

    Correct Answer
    B. The lower order byte of the word
    Explanation
    In Little Endian assignment, the least significant byte of a word is stored first, followed by the more significant bytes. Therefore, when storing a number, the sign bit (which indicates whether the number is positive or negative) will be stored in the lower order byte of the word.

    Rate this question:

  • 22. 

    Whenever a memory location is used, then actual memory address specified through addressing mode, is called the

    • A.

      Effective address

    • B.

      Registry

    • C.

      Immediate address

    • D.

      None of the mentioned

    Correct Answer
    A. Effective address
    Explanation
    The effective address refers to the actual memory address that is specified through the addressing mode when a memory location is being used. It is the address where the data is stored or retrieved from in memory. The other options, such as registry and immediate address, do not accurately describe the concept of the actual memory address specified through addressing mode.

    Rate this question:

  • 23. 

    Let’s say that the word EFBACDFE16 is stored in a memory which is byte addressable, little endianness is followed and 1 word = 2 bytes. Which of the following gives the correct order of bytes storage of the word in memory?

    • A.

      EF DC AB FE

    • B.

      BA EF FE CD

    • C.

      FE CD BA EF

    • D.

      EF BA CD FE

    Correct Answer
    B. BA EF FE CD
    Explanation
    In little endianness, the least significant byte is stored first followed by the most significant byte. In this case, the word "EFBACDFE16" is stored in memory as "BA EF FE CD".

    Rate this question:

  • 24. 

    Consider the byte registers R0 = ABH and R1 = ABH (H stands for Hexadecimal). What will be contents of R0 and R1 after the execution of the instruction Compare R1, R0?

    • A.

      R0 = ABH and R1 = ABH

    • B.

      R0 = ABH and R1 = 00H

    • C.

      R0 = 00H and R1 = 00H

    • D.

      R0 = 00H and R1 = ABH

    Correct Answer
    A. R0 = ABH and R1 = ABH
    Explanation
    After the execution of the instruction Compare R1, R0, the contents of R0 and R1 will remain unchanged and will still be ABH.

    Rate this question:

Back to Top Back to top
Advertisement
×

Wait!
Here's an interesting quiz for you.

We have other quizzes matching your interest.