diff --git a/exercises/verify.cpp b/exercises/verify.cpp index 23356789..21379e92 100644 --- a/exercises/verify.cpp +++ b/exercises/verify.cpp @@ -9,10 +9,27 @@ The number 3 is [not] present in the array. #include using namespace std; +template bool contains(const T* Arr, const size_t& dim, const T& toFind){ + for(size_t i=0; i> toFind; + + if(contains(N, 10, toFind)) + cout << "The number " << toFind << " is present in the array" << endl; + else + cout << "The number " << toFind << "is NOT present in the array" << endl; return 0; }