#include <iostream>
using namespace std;
struct Setting {
//类型字段
static string Path;
//C++ 中没有属性
static int Mode;
//类型方法
static void SetNextMode() {
Mode = (Mode + 1) % 3;
}
};
//初始化
string Setting::Path = "";
int Setting::Mode = 0;
Setting::Mode = 3;
Setting::SetNextMode();
//Setting.Mode is 1
cout << "Mode is " << Setting::Mode;