Posted By: Anonymous
I’m looking at some Python code which used the
@ symbol, but I have no idea what it does. I also do not know what to search for as searching Python docs or Google does not return relevant results when the
@ symbol is included.
@ symbol at the beginning of a line is used for class, function and method decorators.
Read more here:
The most common Python decorators you’ll run into are:
If you see an
@ in the middle of a line, that’s a different thing, matrix multiplication. See this answer showing the use of
@ as a binary operator.