{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

quiz2 - FUNTION HEADER void return type but it accepts two...

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

View Full Document Right Arrow Icon
// Write a function to swap the values contained // in two variables using a third variable ? #include<iostream.h> FUNCTION PROTOTYPE int main() { int x,y; for(int i = 1; i<=3; ++i) { cout<<"enter the values of x and y\n"; cin >>x>>y; FUNTION CAll } return 0; } //*************************************************************
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: FUNTION HEADER ( void return type but it accepts two arguments ) { int third_num; SWAPPPING LOGIC cout<<"After Swapping\n"; cout<<"x: "<<a<<endl; cout<<"y: "<<b<<endl; } enter the values of x and y 12 45 After Swapping x: 45 y: 12...
View Full Document

{[ snackBarMessage ]}