Maison  >  Questions et réponses  >  le corps du texte

c++ - list 能否放置vector类型?

例如这样是否可行:
list < vector< string > > ?

ringa_leeringa_lee2715 Il y a quelques jours699

répondre à tous(3)je répondrai

  • 大家讲道理

    大家讲道理2017-04-17 11:52:10

    std::list<std::vector<std::string> >
    

    当然可以

    répondre
    0
  • 黄舟

    黄舟2017-04-17 11:52:10

    当然可以,不然怎么叫“容器”呢?

    répondre
    0
  • PHP中文网

    PHP中文网2017-04-17 11:52:10

    没有问题,注意语法书写上,最右边的两个>之间需要有个空格,否则语法解析的时候会将其和>>符号混淆;

    list < vector< string > >
    

    répondre
    0
  • Annulerrépondre