Comp242-hwdass - #include <iostream> #include...

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

View Full Document Right Arrow Icon
// Görkem Aksoy 20070756 #include <iostream> #include <stdlib.h> #include <iomanip> using namespace std; u void fillArray(int ar[], int size, int inc); //takes three parameters ar, size and inc and fill the array with respect to these values void printArray(int* ar, int size); //prints the elements in the array void mergeArrays(int a1[], int size1, int a2[], int size2, int a3[]); //merges a2 and a1 then fill them into a3 void shuffle(int* ar, int size); //shuffles the elements in the array pointed by ar int indexOfMinimum(int ar[], int size); //returns the index of the minimum element in the array void sortArray(int* ar, int size,bool (*compare) (int a, int b)); //sorts the elements in the array pointed by ar bool ascending(int,int); //helps to the sort function bool descending(int,int); //helps to the sort function / int *ptr1; //first pointer int *ptr2; //second pointer int *ptr3; //third pointer int first; //first value for ar1 from user int second; //second value for ar2 from user int inc1; //increment that user enters for ar1 int inc2; //increment that user enters for ar2 / int main(){
Background image of page 1

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

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

Page1 / 4

Comp242-hwdass - #include &lt;iostream&gt; #include...

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