Rearranged code blocks