// 7_7-2-4.cpp : コンソール アプリケーションのエントリ ポイントを定義します。
//

#include "stdafx.h"
#include <iostream>
#include <windows.h>
#include <string>

using namespace std;

namespace spc1 {
	string ss = "spc1のssです。";
	void aaa() {
		cout << "spc1のaaa関数です。\n";
	}
	void bbb() {
		cout << "spc1のbbb関数です。\n";
	}
}

namespace spc2 {
	string ss = "spc2のssです。";
	void aaa() {
		cout << "spc2のaaa関数です。\n";
	}
	void bbb() {
		cout << "spc2のbbb関数です。\n";
	}
}

using namespace spc1;

int _tmain(int argc, _TCHAR* argv[])
{
	/* spc1名前空間にアクセス */
	cout << ss << '\n';
	aaa();
	bbb();

	/* spc2名前空間にアクセス */
	cout << spc2::ss << '\n';
	spc2::aaa();
	spc2::bbb();

	MessageBox(NULL, _T("Check Console Window"), L"MessageBox", MB_OK);

	return 0;
}

