Rectangle and Square Patterns - Search