                              _____ _____________279

9.  vector<T>      ,  -
    .   , 
    (quicksort).    -
        STL  -
  100, 1000  10000  (.  9,4,  
vector,  . 251).

10. ()    .    -
    ,     .
  ,      char.  -
    0.      -
.       string.h.
      string.

11.      . 
      (bubblesort).

template <class T>
void bubble( d[], int how_many)

{

 temp;

for (int i = 0; i < how_many - 2; ++i)

for (int j = 0; j < how_many - 1 - i; ++j)
if (d[j] < d[j+l]) {
t emp = d [ j J ;

d[j] = d[j+l] ;

d[j +1] = t emp ;

}

i

 ,  bubble   ,    -
 operator<() ?

12.   quicksort,     
  (.  9.5,  quicksort,  . 254).
           -
      .    -
,       -   1.

13.       10000   0  9999.
    list<int> (.  9.7, STL,  . 259). -
    (median) .   -
?     ,   -
,    ,  ,   . 
,    .   vector<int>
  .

14.   print (consfc list<double> &lst) ,  
  ,      (.  9.7,
STL,  . 259).