// Example 2-20: Using declarations in classes.
#include <cstddef>
#include <vector>

template<typename T>
class array: private std::vector<T>
{
public:
  typedef T value_type;
  using std::vector<T>::size_type;
  using std::vector<T>::difference_type;
  using std::vector<T>::iterator;
  using std::vector<T>::const_iterator;
  using std::vector<T>::reverse_iterator;
  using std::vector<T>::const_reverse_iterator;

  array(std::size_t n, const T& x = T()) : std::vector<T>(n, x) {}
  using std::vector<T>::at;
  using std::vector<T>::back;
  using std::vector<T>::begin;
  using std::vector<T>::empty;
  using std::vector<T>::end;
  using std::vector<T>::front;
  using std::vector<T>::operator[];
  using std::vector<T>::rbegin;
  using std::vector<T>::rend;
  using std::vector<T>::size;
};
