C ++中哪种类型与C#List相同? [英] Which type in C++ is equivalent withC# List ?

查看:133
本文介绍了C ++中哪种类型与C#List相同?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,

我在C#中有一个功能:

Hi all,
I have a function in C#:

public void fn(List<double> pDoub)
{
}





在C ++中,这个函数的原型是什么?提前知道。



In C++, what is prototype of this function? Thannks in advance.

推荐答案

参考:确实有任何类似于listtring-in-c-sharp [ ^ ]


根据要求,这是一个带有函数原型的C ++类。



As requested, here's a C++ class with a function prototype.

#include <vector>

class SomeClass
{

public:

void fn(std::vector<double> &list);

};
</double>





参考:



http://www.cplusplus.com/reference/vector/vector/ [ ^ ]


猜猜你在寻找c ++中的向量,cpp中的列表是完整的链表。
Guess you are looking for a vector in c++, the list in cpp is intact a linked list.


这篇关于C ++中哪种类型与C#List相同?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆