Index
 
  Reference for Wiring 1.0 (ALPHA) 0017+. If you have a previous version, use the reference included with your software. If you see any errors or have any comments, let us know.
Name  

~ (bitwise one´s complement)

   
Examples  
unsigned int value=4;  //   4 = 0000 0100 
 
value = ~ value;       // 251 = 1111 1011 

Description   This operand is unary (requires one operand) and inverts bit by bit of an expression. Returns 0 for that position bit if the position is 1 or 1 if the position is 0. The following list shows all possible combinations:

이 연산은 하나의 데이터를 요구하며 표현식(상수 포함)의 비트를 반전합니다. 1 인 비트는 0 으로 0 인 비트는 1 로 반전하여 반환합니다. 아래는 가능한 모든 조합의 예 입니다. 

~ 0 // Evaluates 1
~ 1 // Evaluates 0

   
Syntax  
~ expression
   
Parameters  
expression   any valid expression

   
Returns   One´s complement of an expression

1 의 보수 (one's compliment)값을 반환합니다.

   
Usage   Application
   
Related   & (bitwise AND)
&= (bitwise AND and assign)
| (bitwise OR)
|= (bitwise OR and assign)
^ (bitwise XOR)
<< (bitwise bit shift left)
>> (bitwise bit shift right)