Swap - << "b =...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
#include <iostream> using namespace std ; int temp ; temp = x ; x = y ; y = temp ; } int main() { int a = 5 ; int b = 3 ; cout << "a = " << a << ", "
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: &lt;&lt; &quot;b = &quot; &lt;&lt; b &lt;&lt; &quot;.&quot; &lt;&lt; endl ; swap (a,b) ; cout &lt;&lt; &quot;a = &quot; &lt;&lt; a &lt;&lt; &quot;, &quot; &lt;&lt; &quot;b = &quot; &lt;&lt; b &lt;&lt; &quot;.&quot; &lt;&lt; endl ; return 0 ; }...
View Full Document

Ask a homework question - tutors are online