Flash CS3 Documentation |
|||
| ActionScript 2.0 Language Reference > ActionScript language elements > Operators > ^= bitwise XOR assignment operator | |||
expression1 ^= expression2
Assigns expression1 the value of expression1 ^ expression2. For example, the following two statements are equivalent:
x ^= y; x = x ^ y;
Availability: ActionScript 1.0; Flash Player 5
expression1 : Number - Integers and variables.
expression2 : Number - Integers and variables.
Number - The result of the bitwise operation.
The following example shows a bitwise XOR assignment (^=) operation:
// 15 decimal = 1111 binary var x:Number = 15; // 9 decimal = 1001 binary var y:Number = 9; trace(x ^= y); // returns 6 decimal (0110 binary)
& bitwise AND operator, &= bitwise AND assignment operator, ^ bitwise XOR operator, | bitwise OR operator, |= bitwise OR assignment operator, ~ bitwise NOT operator
Flash CS3
Send me an e-mail when comments are added to this page | Comment Report
Current page: http://livedocs.adobe.com/flash/9.0/main/00001264.html