1. logical expressions
1. | the operator is a sequence point ).
First, modify the value on the left and then judge the value on the right. For example, I ++ <6 | I = J
First I ++ and then I = J;
2. The priority of the & operator is lower than that of the relational operator.
2. Simple file input and output
Assume that the following example is input: 38.5 19.2
1. Char ch; CIN> CH
The encoding of character 3 is not stored here.
2. Int N; CIN> N;
Cin will continue to read until non-numeric characters are encountered. For example, click. Here.
3. Char word [50]; CIN> word;
Here, the CIN is continuously read until blank characters are encountered.
4. Char word [50]; cin. Getline (word, 50 );
Here, CIN keeps reading until a line break is encountered.
3. file output operation steps:
1. Declare An ifstream variable (object ). Associate objects with files. For example, open ().
2. You can use the ifstream object and operator <to read various types of data.
3. You can use an ifstream object and get () to read a single character and use Getline () to read a row.
4. Check whether the input is successful by combining EOF () and fail.
5. Good () checks whether an error occurs, such as EOF or file downloading.