Here is something close to what you wanted:
$$
\begin{array}{cc}
&
\begin{array}{ccccc} 1 & 2 & 3 & 4 & 5\\
\end{array}
\\
A =
&
\left[
\begin{array}{ccccc}
h & e & l & l & o \\
m & s & e & * & * \\
m & e & t & a & *
\end{array}
\right]
\end{array}
$$
I learned it from http://latex-tricks.blogspot.com/2009/11/matrix-with-row-and-column-labels.html
Essentially you use the nested array environment here so that you don't need to adjust the spaces between the labels.
$$
\begin{array}{cc}
&
\begin{array}{ccccc} 1 & 2 & 3 & 4 & 5\\
\end{array}
\\
A =
&
\left[
\begin{array}{ccccc}
h & e & l & l & o \\
m & s & e & * & * \\
m & e & t & a & *
\end{array}
\right]
\end{array}
$$
[Added] The example in the linked post above gave the following example, which also has row labels:
$$
\begin{array}{c c} &
\begin{array}{c c c} a & b &c \\
\end{array}
\\
\begin{array}{c c c}
p \\
q\\
r
\end{array}
&
\left[
\begin{array}{c c c}
.1 & .1 & 0 \\
.4 & 1 & 0 \\
.8 & 0 & .4
\end{array}
\right]
\end{array}
$$
$$
\begin{array}{c c}
& \begin{array}{c c c} a & b &c \\ \end{array} \\
\begin{array}{c c c}p\\q\\r \end{array} &
\left[
\begin{array}{c c c}
.1 & .1 & 0 \\
.4 & 1 & 0 \\
.8 & 0 & .4
\end{array}
\right]
\end{array}
$$