1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33
|
\subsection{sort}
\label{labsort}
\noindent Name: \textbf{sort}\\
\phantom{aaa}sorts a list of real numbers.\\[0.2cm]
\noindent Library name:\\
\verb| sollya_obj_t sollya_lib_sort(sollya_obj_t)|\\[0.2cm]
\noindent Usage:
\begin{center}
\textbf{sort}(\emph{L}) : \textsf{list} $\rightarrow$ \textsf{list}\\
\end{center}
Parameters:
\begin{itemize}
\item \emph{L} is a list.
\end{itemize}
\noindent Description: \begin{itemize}
\item If \emph{L} contains only constant values, \textbf{sort}(\emph{L}) returns the same list, but
sorted in increasing order.
\item If \emph{L} contains at least one element that is not a constant, the command fails
with a type error.
\item If \emph{L} is an end-elliptic list, \textbf{sort} will fail with an error.
\end{itemize}
\noindent Example 1:
\begin{center}\begin{minipage}{15cm}\begin{Verbatim}[frame=single]
> sort([| |]);
[| |]
> sort([|2,3,5,2,1,4|]);
[|1, 2, 2, 3, 4, 5|]
\end{Verbatim}
\end{minipage}\end{center}
See also: \textbf{revert} (\ref{labrevert})
|