visual studio 2022c语言 我这样 定义一个字符串变量报错 : char * str = "hello";
改成const char * str = "hello";由于"hello"是常量字符串,编译器要求对应的变量类型必须加const