// CS 2310 Execise 5 // Chapter 12. // Implementation file safeArray.cpp #include #include #include #include "safeArray.h" using namespace std; int IntArray::ValueAt( /* in */ int i) const // Precondition: // i is assigned // Postcondition: // IF i >= 0 && i < declared size of array // Function value == value of array element // at index i // ELSE // Program has halted with error message { if (i>=0 && i= 0 && i < declared size of array // val is stored in array element i // ELSE // Program has halted with error message { // Write the implementation here. } IntArray::IntArray() // Postcondition: // Array created with all array elements == 0 { int i; for (i=0; i