本文介绍了Python列表等价于C ++?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
你能告诉我什么是最接近的数据类型在C ++到python列表?如果没有类似的,你将如何在C ++中构建它?
Could you please tell me what is the closest data type in C++ to python list? If there is nothing similar, how would you build it in C++?
推荐答案std :: vector s, std :: list 和数组(或 std :: array s)都有类似于Python列表的功能。您要选择的数据结构取决于您的要求。
std::vectors, std::lists, and arrays (or std::arrays) all have features similar to Python lists. Which data structure you want to choose depends on your requirements.
更多推荐
Python列表等价于C ++?
发布评论