Increment and decrement operations
English: Increment and decrement operations Since you know how add +1 to numerical variables, I am able to show you how do that in a different way using increment statement. Incrementing one unit from variable within this syntax: variable++; This increment operation is called post increment, which this variable is incremented by one. Eg: int myVariable = 20; myVariable++; Console.WriteLine(myVariable); // Output will be 21. But, if you try: int x = 2; int y = x++; The Output from "y" will be 2 and from "x" will be 3. Post increment only add +1 for that variable, but doesn't return this value. Look at the code below: int a = 5; int b = a++; int c = a++ - b++; What is the Output from all of these variables after increment operations? Think a little about this question and then check out the answer: The output from "a" variable is 7, because on second and third line, it is incremented....