# Tag Info

Accepted

### How to respond to the two-handed approach to swapping

Don't overcomplicate things. Your first instinct, that the computer only has one hand, was the correct one. This is a regular problem that new teachers have, and it sometimes takes a few years of ...
• 31.8k

### How to respond to the two-handed approach to swapping

Re-evaluate what you think is "right", because you aren't but isn't right in computer science This is simply incorrect. Your student can create two variables called ...
• 1,072

### How to respond to the two-handed approach to swapping

Your problem is that you tried to let your student "program" without establishing a language. Thus they were free to write their own "language" in which you can do two things at ...
• 1,245

### How to respond to the two-handed approach to swapping

This question reminds me of when a student failed to understand why a third variable was needed to exchange the value of two variables (i.e. to swap A and B, C=A, A=B, B=C). I managed to illustrate ...
• 151

### How to respond to the two-handed approach to swapping

They took both their hands, picked up the second and fourth pencils (each in one hand), and swapped them! That works in reality... but isn't right in computer science. It depends on your paradigm. ...

### How to respond to the two-handed approach to swapping

Analogies & metaphors are imperfect, so let's share the expectation that they are just illustrative. Rules of what is possible (and not) are very important, and we can compare the rules of pencils ...
• 323

### How to respond to the two-handed approach to swapping

I do the swap example pretending to have two largish (2-hands-to-lift) boxes side-by-side on a desk (with only enough room for two boxes). After we lift the first we have to look for a place to put it,...

### How to respond to the two-handed approach to swapping

In thinking about this, and especially the answer of Graham, I think that what we really do in the standard three step process is a two handed swap without thinking of it. So, it is a failure of the ...
• 35.3k

### How to respond to the two-handed approach to swapping

Graham pointed out that the assumtions of the question are wrong. And Peter Cordes elaborated a bit in the comments. Considering a target VLIW (Very Long Instruction Word) architecture can help ...
• 834