Direct numerical simulation of three-dimensional acoustic turbulence has been performed for both weak and strong regimes. Within the weak turbulence, we demonstrate the existence of the Zakharov-Sagdeev spectrum ∝k^{-3/2} not only for weak dispersion but in the nondispersion (ND) case as well. Such spectra in the k space are accompanied by jets in the form of narrow cones. These distributions are realized due to small nonlinearity compared with both dispersion or diffraction. Increasing pumping in the ND case due to dominant nonlinear effects leads to the formation of shocks. As a result, the acoustic turbulence turns into an ensemble of random shocks with the Kadomtsev-Petviashvili spectrum.