-
2.Bitwise or arithmetic (|.))
Perform logic or operations on bits or bits corresponding to two computations, and the rules of operation are the same as those of logic or"||"Same.
Bitwise or expression: c=a|ba:
b:c:1.Bitwise vs. arithmetic.
Bitwise sum is a logical sum of two bits corresponding to the amount of operation"&"The rules of operation are the same as the logic"&&"Same.
Bitwise and expression: c=a&ba:
b:c:3.Bitwise XOR operations ( ).
The rules of bitwise XOR operations are as follows: if the corresponding bits of two operations are the same, the result is 0, and if they are different, the result is 1. Namely:
Bitwise XOR expression: c=a ba:
b:c: It can be seen that the meaning of XOR operation is: if the values of two corresponding bits are different, the result is 1, and if it is the same, it is 0.
4.Bitwise negation operator ( ).
The operation rule of bitwise negation is to negate the operation object represented by binary bits, that is, 1 becomes 0 and 0 becomes 1.
Bitwise XOR expression: c= aa:c:
-
I don't think that's what the other person meant. *p refers to the content of the p pointer. The meaning of this sentence is that at least one of the contents pointed to by p and the content pointed by q is not 0, and this sentence is true; If both are 0, they are false.
As for what to do if one of p or q is empty, I really don't know, you can experiment with it.
-
It has no special meaning, just a normal variable name or a character constant.
Variables can be accessed by variable name. In imperative languages, variables are usually mutable; But in a purely functional language (such as haskell), variables can be immutable. In C, a is a variable.
Note. a-=a means a=a-a, subtract a from a first, and then assign a value to the result. -= is actually an abbreviated form that makes changes to variables more concise.
When calculating, you can write it in a familiar form, and calculate it from right to left, noting that the value of the variable will change every time you calculate, and if you don't pay attention, it will lead to an error.
-
The two double quotation marks in the title are punctuation in Chinese. Chinese punctuation is not available in C language programs, and English punctuation must be used. 'a'In the C language, it is represented as a letter, i.e. the English letter A is capitalized. It takes up one byte when it is stored.
-
b is a backspace, press the backspace key on the keyboard, it is also a character, but when it is displayed, it will return the cursor to the previous character, but it will not delete the character at the cursor position, if there is a new character after it, it will overwrite the returned character, which is not the same as the effect of pressing backspace in the text editor.
backslash b(b) in c (you can remove a character from the output that you just output). For example: printf("abcde");printf("\babcd");, the actual output is abcdabcd (the A of the later output overwrites E).
c The problem of backslash and slash escaping character paths
In c is an escape character, which escapes only one character after it, and in some special cases, it needs to be used in pairs. Some specific uses of escape characters are as follows:
For example, if you want to output this string, you might write @ like this"
But the compiler doesn't let it go through this way, but as you can see in the table above, you can write it like this"\
In addition, when getting the file path, many people like to use d: ; Then the so-called escape character error occurs, and the solution is to use @d: I don't know if this is a problem.
The above content reference: Encyclopedia - backslash.
-
'A' means variable in C. a-=a means a=a-a, subtract a from a first, and then assign a value to the result. -= is actually an abbreviated form that makes changes to variables more concise.
A is not interesting in C, 97 in ASCLL code, the first few are operators, and " " is the beginning of the macro definition.
Left and right binding.
There are two types of conjugation of operators in the C language: left-conjunctive and right-conjugative.
For example, the combination of arithmetic operators is left-to-right, i.e. left first and then right. If there is an expression x-y+z, y should be combined with the "-" sign first, and x-y operations should be executed, and then +z operations should be executed. This left-to-right direction of binding is called "left-bound bonding".
The right-to-left direction of binding is called "right binding". The most typical right-binding operator is the assignment operator. For example, x=y=z, due to the right binding of "=", y=z should be executed first and then x=(y=z) should be executed.
-
Hello dear, x>y is a logical expression, in the C language, it means that the expression is true to take x, otherwise take y, that is, take the greater of the two, and the previous a= is an assignment after the judgment of x and y.
Determine x>y first, if x>y is true, then x, if x>y is false, then find y and then assign x and y.
-
It means "not", which is a kind of logical operation. If the truth value of a is 1, then! a is 0; If the truth of a is 0, then! a is 1.
First of all, b++ means to do a self-additive operation on b, we use c instead, c=b++; >>>More
Indicates that the remainder of 6 is taken.
In the C language, % stands for remainder (or modulo operation). >>>More
Then the CD stream is: choose to dodge when one of your attack skills is temporarily unusable, and attack again when the skill can be used. >>>More
2b is a pen, which can also refer to Hongxing Erke, of course, it can also refer to the landlord.
Zhejiang A means Hangzhou City, Zhejiang B means Ningbo City, and Zhejiang C means Wenzhou City. >>>More