C语言char s[] 和 char *s的差别,以下这个回答解说的非常清晰. The difference here is that char *s = "Hello world"; will place Hello world in the read-only parts of the memory and making s a pointer to that, making any writing operation on this memory illegal. While d
将某一数值赋给某个变量的过程,称为赋值. 1. 简单赋值 C语言规定,变量要先定义才能使用,也可以将定义和赋值在同一个语句中进行 int a = 10 + 5;的运算过程 a = b = 10;的运算过程 等号左边不能是常量,比如10 = 11; 2. 复合赋值 复加减乘除余:a += 4 + 5; #include <stdio.h> int main() { ; // a = a + 5; // 复合赋值运算符 a += ; // a = a + 5; a *= ; // a = a *