Computer Applications
In a statement c = c + (x * d + e); which variable is an accumulator?
- d
- c
- e
- x
Java Operators
6 Likes
Answer
c
Reason — In the statement c = c + (x * d + e);, the variable c appears on both sides of the assignment and continuously stores the updated result by adding new values to its previous value, which is the defining property of an accumulator. The variables x, d, and e are only used to compute the expression once and do not store cumulative results, hence they are not accumulators.
Answered By
3 Likes
Related Questions
The full form of JVM is:
- Java Visible Machine
- Java Virtual Mode
- Java Virtual Machine
- Java Visible Mode
Which of the following occupies 2 bytes of storage?
- 25
- AM
- 35.2
- \\
Which of the following is NOT an access specifier?
- private
- protected
- package
- public
What is the output of the statement
Math.pow(36, 6/5);?- 36.0
- 1.0
- 73.71
- 6.0