Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CPP

cpp vector structure

#include <vector>

typedef struct test1 {
  int a;
  char b;
} TOTO;

std::vector<TOTO> _v;

_v.push_back((TOTO){10, 'a'});
_v[0].a = 101;
Source by en.cppreference.com #
 
PREVIOUS NEXT
Tagged: #cpp #vector #structure
ADD COMMENT
Topic
Name
7+1 =