<image>There are three great circles on a sphere that intersect each other in a right angle. Starting in point S a little bug moves along the great circles in the direction indicated. At crossings it turns alternately to the right or left. How many quarter circles does it crawl along until it is back in point S?