C++完美演繹 經(jīng)典算法 如 /* 頭文件:my_Include.h */ #include <stdio.h> /* 展開C語言的內(nèi)建函數(shù)指令 */ #define PI 3.1415926 /* 宏常量,在稍后章節(jié)再詳解 */ #define circle(radius) (PI*radius*radius) /* 宏函數(shù),圓的面積 */ /* 將比較數(shù)值大小的函數(shù)寫在自編include文件內(nèi) */ int show_big_or_small (int a,int b,int c) { int tmp if (a>b) { tmp = a a = b b = tmp } if (b>c) { tmp = b b = c c = tmp } if (a>b) { tmp = a a = b b = tmp } printf("由小至大排序之后的結(jié)果:%d %d %d\n", a, b, c) } 程序執(zhí)行結(jié)果: 由小至大排序之后的結(jié)果:1 2 3 可將內(nèi)建函數(shù)的include文件展開在自編的include文件中 圓圈的面積是=201.0619264
本章將介紹Windows CE 的儲存管理。我們將本章內(nèi)容分為兩大部分,前半部會依序介紹 Windows CE的檔案系統(tǒng)類型、 Windows CE儲存管理結(jié)構(gòu)和每一個層次、以及如何自行開發(fā)檔案系統(tǒng)並載入之,後半部則以Ramdisk上的檔案系統(tǒng)為例,實際分析儲存管理相關(guān)的原始程式碼與資料型態(tài)。