Computer Science, asked by rahini59, 8 months ago

Which of the following expression can be used to increase the value of A by 1?

a) A++ b) A+=1 c) ++A d) All of these
those who tells me correct answer I will mark as brainliest and thank you​

Answers

Answered by BrainlyProgrammer
17

Answer:

Option d)all of these

Explanation:

Plz mark me brainliest

Answered by pragyakirti12345
0

Answer: (d) All of these

Explanation:

In any programming language, to increase the value of a variable by 1, we simply add 1 to the variable, but this can be done in many ways.

Let the variable be A.

  • To increase the value of variable A by 1, we can simply add 1 to this : A = A + 1
  • There is also a short - hand operator to do this task. A = A + 1 can also be written as A += 1, this also does the same operation of increasing the value of variable by 1.
  • Pre - increment and post - increment can also be used to increase the value by 1. A++ is the post - increment, means it will first use the value of A, then will be increased by 1. ++A is the pre - increment, means the value is first increased and then used.

_______________________________________________

Related Links :

Difference between pre increment and post increment.

https://brainly.in/question/39398525

Pre-increment and Post-increment concept in C/C++?

https://brainly.in/question/9125029

#SPJ2

Similar questions