Initial implementation of loop over blocks