If the mean of the distribution is \(5\), then the value of \(P\) is:
\[ \begin{array}{|c|c|c|c|c|c|} \hline x_i & 2 & 4 & 6 & P & 10 \\ \hline f_i & 3 & 2 & 1 & 4 & 2 \\ \hline \end{array} \]
Find the mean and mode of the following data:
| Class | 15--20 | 20--25 | 25--30 | 30--35 | 35--40 | 40--45 |
| Frequency | 12 | 10 | 15 | 11 | 7 | 5 |