Elements of spectral theory without the spectral theorem