\begin{Schunk}
\begin{Sinput}
 grep("Texas$", cities, value = TRUE)
\end{Sinput}
\begin{Soutput}
[1] "Dallas Texas" "Austin Texas"
\end{Soutput}
\end{Schunk}
