Let $B(n)$ be the number of ones in the base two expression for the positive integer $n.$ Determine whether
$$\exp \left( \sum_{n=1}^{\infty} \frac{ B(n)}{n(n+1)} \right)$$
is a rational number.
1. We start by considering the function \( B(n) \), which counts the number of ones in the binary representation of the positive integer \( n \).

2. We need to evaluate the expression:
   \[
   \exp \left( \sum_{n=1}^{\infty} \frac{B(n)}{n(n+1)} \right)
   \]

3. First, we analyze the contribution of each digit in the binary representation of \( n \) to \( B(n) \). The last digit (least significant bit) contributes to \( B(n) \) if \( n \) is odd. Therefore, the sum of contributions from the last digit is:
   \[
   \sum_{\substack{n=1 \\ n \text{ odd}}}^{\infty} \frac{1}{n(n+1)}
   \]

4. We can rewrite the sum for odd \( n \) as:
   \[
   \frac{1}{1 \cdot 2} + \frac{1}{3 \cdot 4} + \frac{1}{5 \cdot 6} + \cdots
   \]

5. This series can be simplified using partial fractions:
   \[
   \frac{1}{n(n+1)} = \frac{1}{n} - \frac{1}{n+1}
   \]

6. Therefore, the series becomes:
   \[
   \left( \frac{1}{1} - \frac{1}{2} \right) + \left( \frac{1}{3} - \frac{1}{4} \right) + \left( \frac{1}{5} - \frac{1}{6} \right) + \cdots
   \]

7. This is a telescoping series, and it sums to:
   \[
   1 - \frac{1}{2} + \frac{1}{3} - \frac{1}{4} + \cdots = \log(2)
   \]
   (This result follows from the Taylor series expansion of \(\log(1+x)\) evaluated at \(x=1\)).

8. Next, we consider the contribution of the next-to-last digit. This digit contributes to \( B(n) \) if \( n \equiv 2 \) or \( 3 \pmod{4} \). The sum of contributions from the next-to-last digit is:
   \[
   \sum_{\substack{n=1 \\ n \equiv 2,3 \pmod{4}}}^{\infty} \frac{1}{n(n+1)}
   \]

9. This series can be written as:
   \[
   \frac{1}{2 \cdot 3} + \frac{1}{3 \cdot 4} + \frac{1}{6 \cdot 7} + \frac{1}{7 \cdot 8} + \cdots
   \]

10. Using partial fractions again, we get:
    \[
    \frac{1}{2} - \frac{1}{4} + \frac{1}{6} - \frac{1}{8} + \cdots = \frac{1}{2} \log(2)
    \]

11. By repeating this argument for each digit in the binary representation, we find that the \( n \)-th last digit contributes:
    \[
    \frac{1}{2^{n-1}} \log(2)
    \]

12. Summing these contributions, we get:
    \[
    \sum_{n=1}^{\infty} \frac{1}{2^{n-1}} \log(2) = \log(2) \sum_{n=1}^{\infty} \frac{1}{2^{n-1}}
    \]

13. The geometric series \(\sum_{n=1}^{\infty} \frac{1}{2^{n-1}}\) sums to:
    \[
    \sum_{n=1}^{\infty} \frac{1}{2^{n-1}} = 2
    \]

14. Therefore, the entire sum is:
    \[
    \log(2) \cdot 2 = 2 \log(2)
    \]

15. Finally, we need to evaluate the exponential of this sum:
    \[
    \exp \left( 2 \log(2) \right) = \exp \left( \log(4) \right) = 4
    \]

16. Since 4 is a rational number, we conclude that the given expression is a rational number.

The final answer is \( \boxed{ 4 } \)