Lol, you get 10 results if you include it in quotes, none of them containing the string ;-).
–
GamecatJul 31 '09 at 14:02

1

I get the error "$# is no longer supported" on Perl 5.10
–
Brad GilbertJul 31 '09 at 14:05

3

Somebody claim those bonus points. I've worked with perl but I've never reached the level where this code snippet would be comprehensible to me. You can tell, because I'm still sane.
–
quillbreakerJul 31 '09 at 14:07

13

I think you forgot to post the code and just mashed your keyboard.
–
SalgarJul 31 '09 at 14:16

Neat, but could you clarify how does this help with searching for a keyword with special characters in Google Search? Cheers!
–
sdaauFeb 23 at 22:00

@sdaau Originally, this question was posted to Stackoverflow with the title "How can I search for "-f>@+?*<.-&'_:$#/%!" on Google?` or something similar. Someone hastily decided the question was not a programming question, and it has been kicked around, changed, merged, morphed several times since then. My answer has moved around with it. See also What is "-f>@+?*<.-&'_:$#/%!" in Perl?.
–
Sinan ÜnürFeb 24 at 1:59

The trick is word and character distance and association. A search for "a* search"brings up the Wikipedia page as the first relevant result. It may treat the "*" as a space, but it works due to the association with "search".
–
KillroyJul 31 '09 at 14:09

Interestingly searching for "A*" on Bing yields the Wikipedia page as the first result, Google gives me a bunch of noise. Maybe locally relevant noise for "A" but not what I wanted :)
–
JoeyAug 3 '09 at 19:41

Google does have some special cases for some punctuation. A search for C# turns up expected results. Shame A* doesn't.
–
NelsonAug 31 '09 at 20:12

Google doesn't search for punctuation characters as far as I know. In this case what you might want to try is to search with a description of your characters: something like plus equals or plusequals. That will probably find you something, especially if you add the programming language to your query (PHP in this case).

This is a good approach, but you will probably also get many unrelated answers. For this particular case, you're lucky, because if you search for plusequal in Google, the first hit is to this article: += plus equal sign - C / C++ answers, which is probably a good answer to what you want.
–
aweApr 19 '11 at 7:22

This is because the phrase C++ is indexed specially. You actually don't need the quotes. See the answer from Senseful. So the C++ gets valid hits for C++ (not C and C#) because it is indexed, but "1+2" ignores the + and returns all that contain 1 and 2 because 1+2 is not indexed.
–
aweApr 19 '11 at 7:31

It seems that almost no one has understood the ops question. He is not asking how to use += as part of a Google search. He is asking how he might search for the definition of += in a search engine that largely ignores special characters.

@ChrisF, you need to first understand what you're searching on in order to better phrase your query.

+= is a common assignment operator in almost any language. If you're specifically after a PHP definition then you might try PHP assignment operators. For string concatenation you would use .= which loosely translates to and equals.

For integers it would perform a mathematical operation. Refer this link for more information.