Google doesn't like -2 * 2

Searching for "-2 * 2" or any other number between 1 and 9 in the format "-<num> * <num>" results in a long delay (~5 seconds) and empty SERP.

  • This also happens if you search for, say, -1 1. At the time of this comment, there has been multiple people hypothesizing behaviors like "confuses it" or "causing a loop". I offer a possible explanation more grounded in information retrieval basics.

    Yes, one indeed is including and excluding the search term, ensuring that no results satisfy the query. Why does this take so long? Probably, Google evaluates a query until it retrieves the 30 or so most relevant results and returns them. But with the contradictory query, none are found, and so the retrieval continues until it times out.

    But if you should try "-13 13", we do get results; this suggests that there is a mode of retrieval gated by the query terms being more than one character in length.

    If we should try, say, "q -q", the number of results and retrieval time does not pop up. however, it seems to take comparably long to execute.

    Trying out "c -c", however, we still get the no. of results display, along with the retrieval time. A card also pops up showing the calculation as interpreting c to be the speed of light.

    Thus it seems that the results counter and retrieval time is displated whenever Google has something to say regarding the query, even if it is not a search result; but it does not display it when it has absolutely nothing to say. But even if it has nothing to say, it still spends the same large amount of time attempting to retrieve results.

  • Ambiguous

    - is used to exclude results

    * is a wildcard

    There's other search options i.e. for date ranges, "inurl:", "filetype:", and looking for exact string matches using quotes. But sometimes they don't work as well. Try:

      "define:-2*2"
    
      "2 * -2 * +2"

  • Played around with this for a minute, interesting find. It seems to trigger a parsing ambiguity, but only for specific forms of that query.

    Notably, this doesn't happen for other multiplies I randomly plugged in involving a positive and a negative. 2 * -2 has the same slow behavior as well, but if you remove the whitespace from the query, or rewrite the -2 as -(2) or (-2), it runs fast again.

    Removing the white space from the query with the -2 as the first value doesn't speed it up, only adding the parens does.

    I think the big clue to what's actually going on is on parses that run in the normal amount of time, Google also returns actual search results. I'm guessing the slowness is coming from the search service timing out, but the calculator service still returns, so you still get a result at all.

    Good stuff, thanks for sharing.

  • "-2 * 2" shows the calculator with the correct result.

    As others mentions maybe the minus is seen as exclusion parameter. So I tried "-test test" which shows empty results. However searching "-2 2" (without the wildcard, shows an empty map tile with "Map for -2 2", funny.

  • I think it might be related to the fact that you are excluding a keyword (-2) then including it (2). That confuses it, maybe causes a loop?

  • It needs time to determine if you are searching the web for any text with "* 2" excluding (-) "-2". I'm sure that over time with enough of the same calculation requests from different users it will become much faster at producing the correct response, due to machine learning.

  • When I enter this in the Chrome search bar, it returns the correct answer immediately in the dropdown menu.

    When I hit Enter to submit the search, there's a delay while it loads the calculator over my slow connection, then shows the calculator with the correct answer in the display.

    No problem.

  • Seems like there is some issues with the -2 without a space in them.

    - 2 + 2 works fine while -2 + 2 does not. -2 +2 seems working though.

    Also, try to search "-2" to get no results.

  • Same with "-2 + 2". Maybe it is loading its calculator implementation in JavaScript (including all dependencies).

  • I don't know how long google has offered the calculator but I discovered it recently. I now use it daily. Awesome.

  • The time to complete the calculation was the same as 25*5 or any other calculation I tried.

  • No problem here (Norway).

  • the is no problem with +2 +2