Let the total work be \(W\).
Work done by A in 1 day = \(\frac{1}{15}\) of \(W\).
Work done by A and B together in 1 day = \(\frac{1}{10}\) of \(W\).
Let the work done by B in 1 day be \(b\).
The total work done by A and B together in 1 day is:
\[
\frac{1}{15} + b = \frac{1}{10}
\]
Solving for \(b\):
\[
b = \frac{1}{10} - \frac{1}{15} = \frac{3 - 2}{30} = \frac{1}{30}
\]
Therefore, B alone will take 30 days to finish the work.
Answer: \(25\)