QUESTION IMAGE
Question
what is the main purpose of a boolean data type in a program?
d) to perform complex multiplication.
b) to represent quantities with decimals.
a) to store long paragraphs of text.
c) to control logic and decision - making.
question 5
what is the key difference between a real number and an integer?
a) real numbers can be negative.
c) real numbers include decimals or fractions.
d) integers are processed faster by the cpu.
b) integers can only be used for counting.
A Boolean data type in programming has two values, true and false, and is mainly used for conditional statements and decision - making in control flow. Real numbers include integers but also fractions and decimals, while integers are whole numbers (positive, negative, or zero).
Snap & solve any problem in the app
Get step-by-step solutions on Sovi AI
Photo-based solutions with guided steps
Explore more problems and detailed explanations
- C) To control logic and decision - making
- C) Real numbers include decimals or fractions