rearrange borghol work explanation