TITLE: Is $8$ the only number with four divisors, the second largest of which is even?
QUESTION [5 upvotes]: Recently I thought about the number $8$.

Is $8$ the only number with four divisors, the second largest of which is even? 

$8$ certainly is such a number, since its divisors are $1, 2, 4$, and $8$ itself. If it is the only one, how can I prove it?

REPLY [7 votes]: It is true. 
For a number to have exactly four divisors, we require that it is either $p^3$ with $p$ prime (case 1) or else $qp$, with $p, q$ different primes (case 2).
However, as its second largest divisor is even, the number is even. Thus, in the first case the only possible prime is $2$, giving us the number $8$, and in case $2$ we have $2p$, with $p>2$. But then its second largest divisor will be $p$.
Hence the only number with your property is $8$.

REPLY [3 votes]: Every positive integer has a unique factorisation into the form $p_1^{\alpha_1}p_2^{\alpha_2}\dotsm p_k^{\alpha_k}$ for primes $p_i$ and nonnegative integers $\alpha_i$. The number of divisors of such a number is $(\alpha_1+1)(\alpha_2+1)\dotsm(\alpha_k+1)$, so in order for a number to have exactly $4$ distinct divisors, then it must be either of the form $p^3$ for some prime $p$, or the form $pq$ for distinct primes $p$ and $q$. Now, since your second largest divisor is even, then the number itself must be even, so that $2$ must be one of the primes dividing it. In the first case this gives rise to $2^3=8$ as you observed. In the second case, the second largest divisor of an integer of the form $2q$ must be $q$, but since $q\neq2$ is prime then it must be odd. So you are right, $8$ is the only such number.

REPLY [3 votes]: Take an $n$ with the aforementioned properties. Since $n$ has an even divisor, it must be divisible by two. Then, for its second largest divisor $\frac n2$ to be even, $n$ must be a multiple of $4$. 
Now, suppose that there existed some prime $p\neq2$ that divided $n$. This would mean that $$1,2,4,p,2p,4p$$ are six different divisors of $n$, which is impossible. Therefore, $n$ must be a power of $2$. However, $2^k$ has $k+1$ divisors $$1,2,4,\ldots,2^k.$$ The only possibility is therefore that $k=3$ and $n=8$. That is, $n=8$ is the only number with your properties. $\blacksquare$