func_fun.cpp

Func_fun.cpp - int temp temp=input1 input1=input2 input2=temp/The following function void order(int& input1 int& input2 if(input1> input2

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
#include <iostream> using namespace std; void get_input(int& input1, int& input2); void order(int& input1, int& input2); void give_results(int output1, int output2); void swap_values(int& input1, int& input2); give_results1(int output1, int output2); void order1(int! input1, int& input2); int main() { int first_num, second_num; get_input(first_num, second_num); order(first_num, second_num); give_results(first_num, second_num); return 0; } // The following function { cout << "Enter two ints: "; cin >> input1 >> input2; } //The following function {
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Background image of page 2
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: int temp; temp=input1; input1=input2; input2=temp; } //The following function void order(int& input1, int& input2) { if (input1 > input2) swap_values(input1, input2); } //The following function void give_results(int output1, int output2) { cout << "In increasing order the numbers are: " << output1 << " " << output2 << endl; } //The following function void order1 (int& input1, int& input2) { if {input1<input2) swap_values(input1, input2) } //The following function give_results1(int output1, intouput2) { cout<<"In decreasing order the numbers re:" <<output2<<" " <<output1 << endl; }...
View Full Document

This homework help was uploaded on 04/17/2008 for the course EECS 168 taught by Professor Miller during the Spring '08 term at Kansas.

Page1 / 2

Func_fun.cpp - int temp temp=input1 input1=input2 input2=temp/The following function void order(int& input1 int& input2 if(input1> input2

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online