qfedu-c-level/day10/d13.c

9 lines
182 B
C

#include <stdio.h>
#include <stdlib.h>
int main()
{
char *p = "disen";
free(p); // 释放常量区的内存,会报错; 因为常量区的内存是只读的
return 0;
}