header file decs class ArrayIntStorage { public: ArrayIntStorage(void); ~ArrayIntStorage(void); void setReadSort(bool sort); bool returnReadIn() { return _sortRead; }; void sortStd(); void sortOwn(); void AddData(int pos, int value); int getData(int pos); private: bool _sortRead; int _data[10000]; }; // reads in if(!i.returnReadIn()) { while (in.good()) { getline (in, line); int Item = atoi(line.c_str()); if(Item > 0) { i.AddData(counter, Item); counter++; } } } void ArrayIntStorage::AddData(int pos, int value) { _data[pos] = value; }