Home  >  Q&A  >  body text

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

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

ringa_leeringa_lee2765 days ago712

reply all(3)I'll reply

  • 大家讲道理

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

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

    Of course

    reply
    0
  • 黄舟

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

    Of course you can, otherwise why would you call it a "container"?

    reply
    0
  • PHP中文网

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

    No problem, please pay attention to the grammar writing. There needs to be a space between the two rightmost >, otherwise it will be confused with the >> symbol during grammar parsing;

    list < vector< string > >
    

    reply
    0
  • Cancelreply