## 22.3 Template Classes (cont.)

- To use:

  > `Pair p = minmax(data);
  > cout << p.get_first() << " " << p.get_second() << "\n";`

Example: non-template class:

>     class Pair
>     {
>        public:
>           Pair(int a, int b);
>           int get_first() const;
>           int get_second() const;
>        private:
>           int first;
>           int second;
>     };

prev |top |next