wrote comparison operators for square and testing script