template_DefaultType
2024-09-06 02:52:40
#include <iostream>
using namespace std; template <typename T1,typename T2=int>
class Test{
public:
T1 NumNBei(T1 num,T2 N)
{
return num*N;
}
}; void main()
{
Test<double> t;
double x= t.NumNBei(2.3,);
cout<<x<<endl;
/*
4.6
Press any key to continue
*/
}
最新文章
- VIM教程
- Linux shell脚本编程(二)
- tomcat 动态部署
- fir.im Log Guru 正式开源,快速找到 iOS 应用无法安装的原因
- ma60笔记
- Android 关于ExpandableListView去掉里头的分割线
- ext DateTime.js在ie下显示不全
- Magento的价格去掉小数点
- java 四种内部类和内部接口
- js之dom_2
- bzoj3144
- Python教程:ORM连接Sqlite数据库,软件架构基础
- 【转】 iOS Provisioning Profile(Certificate)与Code Signing详解
- codevs 1061 重复子串
- Scrapy安装问题
- Arduino 入门程序示例之一排 LED(2015-06-11)
- 分步理解 Promise 的实现
- Redis学习笔记之Redis的对象
- maven 项目 编码
- django-vue之信息过滤(过滤课程)