SYMBOL CARET

Jul 8, 2014 at 12:48pm
Hello, I wanted to ask a question?
Is the symbol "^" or caret is a valid operator in c++? Reason? As for me, I think it is valid, because the symbol itself represent as the pointer to another variable and yet can be defined by c++. What about yours..?
Jul 8, 2014 at 1:03pm
It's XOR in C, C++ and C#.
Jul 8, 2014 at 3:47pm
closed account (z05DSL3A)
farahani wrote:
Is the symbol "^" or caret is a valid operator in c++? Reason? As for me, I think it is valid, because the symbol itself represent as the pointer to another variable and yet can be defined by c++. What about yours..?
Me much with the not understanding.
Jul 8, 2014 at 3:52pm
The ^ is the bitwise XOR operator (exclusive OR) . A bitwise operator is used when working with individual bits and are used to mask bits together. The bitwise operators include:

& bitwise AND
| bitwise OR
^ bitwise XOR
~ (unary) bitwise NOT

I suggest you read up on that. Check the Tutorials section on this site.
Topic archived. No new replies allowed.