solved squares finding problem