We use temp because otherwise you would loose a value. Think like you have two cups (A and B) in two positions (1 and 2 respectively) that each of them can place only one cup and you can carry only...
Type: Posts; User: andreas90
We use temp because otherwise you would loose a value. Think like you have two cups (A and B) in two positions (1 and 2 respectively) that each of them can place only one cup and you can carry only...
After the rotation the values have moved one step forward with the last value going to the first variable (like a cycle).
after initialization
a b c d temp
10 20 30 40 -
...
Hello unleashed-my-freedom!
What is your question? You use the temp variable to rotate the values of your "basic" variables (a,b,c,d). So, you give every variable the value of the next (or previous)...