Computational Logic And Boolean Algebra Flashcards

1
Q

What is computational logic?

A

Computational logic involves using logic gates and Boolean algebra to make decisions based on inputs in computing systems.

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

What is a Boolean value?

A

A Boolean value is a data type that can only be one of two values: True or False.

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

What are the three basic Boolean operators?

A

The three main Boolean operators are AND, OR, and NOT.

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

What does the AND operator do?

A

The AND operator returns True only if both inputs are True.

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

What does the OR operator do?

A

The OR operator returns True if at least one input is True.

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

What does the NOT operator do?

A

The NOT operator inverts the input. If the input is True, it returns False, and vice versa.

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

What is a truth table?

A

A truth table shows all possible input combinations for a logic circuit and their corresponding outputs.

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

What is a logic gate?

A

A logic gate is a physical or simulated device that implements a Boolean function using electronic signals.

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

How does the expression A AND (NOT B) behave?

A

It is only True when A is True and B is False.

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

What is the difference between A OR B and A AND B?

A

A OR B is True if either input is True, while A AND B is True only if both are True.

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

What is meant by combining Boolean operators?

A

You can create complex conditions by combining AND, OR, and NOT in expressions, such as NOT(A AND B) or A OR (B AND C).

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

How do you apply Boolean logic in code or pseudocode?

A

Boolean expressions are used in decision structures like if statements or loops to control the flow of a program.

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

What is the practical use of Boolean logic in computing?

A

Boolean logic is used in decision-making, program control, database queries, and designing digital circuits.

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

What is the precedence of Boolean operators?

A

The order of precedence is: NOT first, then AND, then OR. Parentheses can be used to change the order.

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

How can you simplify a logic circuit using Boolean algebra?

A

By applying logical rules like De Morgan’s Laws to reduce the number of gates or simplify expressions.

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