f*******l 发帖数: 1239 | 1 2 Strings walk into a bar.First one says "I'll have a rum & cokeazx32@$[
5x4ceg".Second one says "Excuse my friend, he's not null terminated" |
E*****m 发帖数: 25615 | 2 C programmers 才懂的
【在 f*******l 的大作中提到】![](/moin_static193/solenoid/img/up.png) : 2 Strings walk into a bar.First one says "I'll have a rum & cokeazx32@$[ : 5x4ceg".Second one says "Excuse my friend, he's not null terminated"
|
f*******l 发帖数: 1239 | |
N******p 发帖数: 2777 | 4 别琢磨了。等你弄明白在看也就不可笑了
【在 f*******l 的大作中提到】![](/moin_static193/solenoid/img/up.png) : 就是在这找牛人啊
|
w*******g 发帖数: 9932 | 5 Should be 2 C-Strings walked into a bar.
That way, you will understand that the String is just an array of characters
needing an '\0' to terminate, or it will print out junk.
【在 f*******l 的大作中提到】![](/moin_static193/solenoid/img/up.png) : 2 Strings walk into a bar.First one says "I'll have a rum & cokeazx32@$[ : 5x4ceg".Second one says "Excuse my friend, he's not null terminated"
|
j****e 发帖数: 12067 | 6 冷
【在 f*******l 的大作中提到】![](/moin_static193/solenoid/img/up.png) : 2 Strings walk into a bar.First one says "I'll have a rum & cokeazx32@$[ : 5x4ceg".Second one says "Excuse my friend, he's not null terminated"
|
E*****m 发帖数: 25615 | |
f*******l 发帖数: 1239 | 8
characters
Thanks very much
【在 w*******g 的大作中提到】![](/moin_static193/solenoid/img/up.png) : Should be 2 C-Strings walked into a bar. : That way, you will understand that the String is just an array of characters : needing an '\0' to terminate, or it will print out junk.
|