STL的小程序,高手不必看了。
// STL学习2.cpp: 主项目文件。
#include "stdafx.h"
using namespace System;
template <class T>
inline const T& max(const T& a,const T& b )
{
return a>b?a:b;
}
int main(array<System::String ^> ^args)
{
Console::WriteLine(L"Hello World");
int imax;
imax=max(12,14);
Console::WriteLine(imax);
Console::ReadKey();
return 0;
}