I. Possible combinations:
(1) const char * P
(2) Char const * P
(3) char * const P(4) const char ** P
(5) Char const ** P
(6) char * const * P
(7) Char ** const P
Of course, there are several cases of inserting a const in (5), (6), and
One, possible combinations:(1) Const CHAR*P(2) Char Const*p(3) Char *const p(4) const char **P(5) Char Const**p(6) Char *const *p(7) Char **const pOf course, in (5), (6), (7) and then insert a const in a number of cases, but the analysis of the
Problem introduction:During the internship, a default error was found, which is also char * c = "ABC" and char C [] = "ABC ", the former changes its content programs will crash, while the latter is completely correct.Program Demonstration:Test
Where can I find the source?
Char * c = "ABC" and char C [] = "ABC", where the former changesThe program crashes, and the latter is completely correct.Program Demonstration:Test Environment devc ++Code# Include Using namespace STD;Main (){Char * C1 =
Problem introduction:During the internship, a default error was found, which is also char * c = "abc" and char c [] = "abc". The former changes the default error.
The program crashes, and the latter is completely correct.Program Demonstration:Test
Problem introduction:During the internship, a default error was found, which is also char * c = "ABC" and char C [] = "ABC". The former changes the default error.
The program crashes, and the latter is completely correct.Program Demonstration:Test
Binary negative Number:The original code is the original representation methodAnti-code is the inverse of the sign bit (highest bit)Complement = anti-code +1 1 bytes It can only represent 256 numbers anyway, because there is a sign, so we're going
Oracle defines string types VARCHAR2 and char specify the length of the usage as follows:VARCHAR2 ( ) is a number between 1~4000 that represents up to 4000 bytes of storage space.char ( ) is a number between 1~2000 that represents up to 2000 bytes
Char * P = "ABC" is different from Char P [] = "ABC"Problem introduction:During the internship, a default error was found, which is also char * c = "ABC" and char C [] = "ABC". The former changes the default error.The program crashes, and the latter
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.