A naive implementation of wavelet trees