Why are space telescopes able to make better observations in the ultraviolet and infrared ranges than ground-based telescopes?

A)space telescopes are closer to the objects that they are observing
B) the atmosphere absorbs or reflects much of the UV and IR radiation
C) space telescopes have larger mirrors and lenses to detect more wavelengths
D) because UV and IR are electromagnetic radiation, they're affected by earth's magnetic field.