多文件編譯
文件位置指示
(1) <stdio.h> : 尖括號表示文件在系統(tǒng)路徑中
(2) "abc/myhead.h":表示abc目錄下的myhead.h
myhead.h:
#define MAX 300 // #define就是簡單的字符串替換
main.c:
#include <stdio.h>
#include "abc/myhead.h"
int main(){
int c = MAX;
printf("%d",c)
}
文件位置指示
(1) <stdio.h> : 尖括號表示文件在系統(tǒng)路徑中
(2) "abc/myhead.h":表示abc目錄下的myhead.h
myhead.h:
#define MAX 300 // #define就是簡單的字符串替換
main.c:
#include <stdio.h>
#include "abc/myhead.h"
int main(){
int c = MAX;
printf("%d",c)
}