Skipping pages with the use of condition