Computer Knowledge

Digital Logic and Microprocessors

735 Questions

Digital logic and microprocessors form the core of computer science, covering logic gates, combinational and sequential circuits, and CPU architecture. These topics are crucial for computer knowledge sections in technical exams. Test your digital electronics basics here.

Logic gates and circuitsCombinational vs sequential circuitsMicroprocessor instructionsTruth tables and boolean functions

Digital Logic and Microprocessors Questions

Multiple choice technology mainframe
  1. R8

  2. R12

  3. R9

  4. R10

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

When a TPF program is executing, Register 9 (R9) is designated to point to the ECB (Event Control Block). The ECB contains crucial information about the program's execution context, and R9 is the architecturally defined register that holds this pointer, allowing the program to access control information.

Multiple choice technology embedded technologies
  1. while(1) { LED(On) Delay(25) LED(Off) }

  2. main() { LED(On) Delay(25) LED(Off) while(1) { } }

  3. while(1) { LED(On) Delay(25) LED(off) Delay(25) )

  4. while(1) { Delay(25) LED(on) Delay(25) }

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

To blink an LED at equal intervals indefinitely, the code must loop continuously, toggle the LED state, and apply a delay after both turning it on and turning it off. Option 569320 correctly includes delays in both states within a while(1) loop, whereas others omit crucial delays or loops.

Multiple choice technology embedded technologies
  1. Resistance is generated

  2. Inductance is generated

  3. Capacitance is generated

  4. Current is generated

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

Capacitive touch sensors like the CY8C20434 work by detecting changes in capacitance when a finger touches the PCB. The human body acts as a capacitor, and when placed near the sensor electrodes, it changes the capacitance of the circuit, which the microcontroller detects as a touch event. Option C is correct.

Multiple choice technology
  1. (a) Decision map

  2. (b) Decision tree

  3. (c) Decision table

  4. (d) When rule

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

When rules in Pega are specifically designed to return boolean outcomes only - either true or false. Unlike decision trees, tables, and maps which can return various data types (strings, numbers, etc.), When rules are strictly boolean conditions used for conditional logic.

Multiple choice technology
  1. (a) True

  2. (b) False

  3. Sometimes true

  4. sometimes false

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

Decision shapes in flowcharts require a path for each logical branch, not for every possible return value. A decision typically has 2-3 paths (yes/no, or multiple mutually exclusive conditions) regardless of how many distinct values the processing might produce. For example, a decision checking 'is x > 0' has two paths (yes/no) even though x could have infinite possible values.

Multiple choice technology programming languages
  1. Bitwise XOR

  2. Bitwise OR

  3. Logical OR

  4. Logical AND

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

Among the listed operators, Bitwise XOR (^) has the highest precedence. The precedence order is: Bitwise XOR (^) > Bitwise OR (|) > Logical AND (&&) > Logical OR (||). The answer is A because XOR ranks highest. Bitwise operators generally have higher precedence than logical operators, and within bitwise operators, XOR outranks OR. This affects expressions like a ^ b | c - XOR binds tighter.

Multiple choice technology web technology
  1. (a) Decision map

  2. (b) Decision tree

  3. (c) Decision table

  4. (d) When rule

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

When rules (Rule-Declare-When) evaluate conditions and return only Boolean true/false results. Decision tables, trees, and maps can return various values - strings, numbers, or other data types. Only When rules are restricted to Boolean outputs.

Multiple choice technology web technology
  1. True

  2. False

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

The statement is false - while you can create connectors for every possible return value from a Decision shape, it is not required. Pega flows can include default handling or error cases where not every return value needs an explicit connector. The best practice is to handle expected outcomes explicitly, but the system does not mandate connectors for all possible returns.

Multiple choice technology programming languages
  1. Mulitplying by 2*n and Dividing by 2*n

  2. Dividing by 2*n and Multiplying by 2*n

  3. Multiplying by n and Dividing by n

  4. Dividing by n and Multiplying by n

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

Left shifting by n bits multiplies by 2^n (each position shift is a power of 2). Right shifting divides by 2^n. This is fundamental to binary arithmetic.

Multiple choice technology embedded technologies
  1. ADD

  2. XOR

  3. MOV

  4. SUB

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

The MOV instruction transfers data between registers or memory locations without performing any arithmetic or logical operation. Since it doesn't modify the data, it doesn't affect processor flags like Zero, Sign, Carry, or Overflow. Instructions like ADD, SUB, and XOR perform operations that modify these flags based on their results.

Multiple choice technology operating systems
  1. CRC

  2. Parity

  3. Both

  4. None

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

SCSI-3 employs Cyclic Redundancy Check (CRC) for robust error detection of data transferred on the bus, replacing the simpler single-bit parity used in SCSI-1 and SCSI-2. CRC can detect multiple bit errors and provides better data integrity protection. Parity was the legacy method, while CRC is the modern standard.

Multiple choice technology storage
  1. CRC

  2. Parity

  3. Both

  4. None

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

SCSI-3 employs Cyclic Redundancy Check (CRC) for robust error detection of data transferred on the bus, replacing the simpler single-bit parity used in SCSI-1 and SCSI-2. CRC can detect multiple bit errors and provides better data integrity protection. Parity was the legacy method, while CRC is the modern standard.

Multiple choice technology databases
  1. It is having two ports nextval and currval

  2. We can add ports in it

  3. It is active and connected

  4. All of the above

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

The Sequence Generator transformation has exactly two ports: NEXTVAL (generates the next sequence value) and CURRVAL (returns the current sequence value). These are the only ports available and you cannot add custom ports to this transformation. It is a passive transformation and not connected to the data flow directly.

Multiple choice technology mainframe
  1. ADDR1 will execute until R2 becomes 0.

  2. ADDR1 will execute until R2 becomes 8.

  3. ADDR1 will never be executed.

  4. All of the above.

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

The BCTR (Branch on Count Register) instruction decrements the register (R2) by 1. If R2 is not 0, it branches. Since it loops back to ADDR1 and decrements R2, the loop at ADDR1 will execute repeatedly until the register R2 becomes 0.