/* * File: arrayFun.h * Purpose: Some fundamental operations on arrays. It may prove * useful in lab 7. */ #ifndef ARRAY_FUN_H #define ARRAY_FUN_H // print n elements in the array void printArray(int ar[], int n); // swap element i and element j in an array void swap(int ar[], int i, int j); // return the index of an item in the array int linearSearch(int needle[], int n, int haystack); #endif