C++ arrays are fixed in size.
If you need a “resizable array”, you’ll want to use std::vector instead of an array.
More Related Contents:
- sizeof works unusual at c++ after array creation [duplicate]
- When a function has a specific-size array parameter, why is it replaced with a pointer?
- How does this “size of array” template function work? [duplicate]
- Using sizeof on arrays passed as parameters [duplicate]
- Invalid operands to binary expression while implementing vector [closed]
- For loop with an array
- can’t extract data from a structure array c++ [closed]
- How would I implement Arrays into this code
- Initialization of all elements of an array to one default value in C++?
- How to return an array from a function?
- Can placement new for arrays be used in a portable way?
- Printing an array in C++?
- Comparing arrays for equality in C++
- c++ array assignment of multiple values
- Common array length macro for C? [duplicate]
- pointer to array c++
- Finding smallest value in an array most efficiently
- Can sizeof return 0 (zero)
- Can std::begin work with array parameters and if so, how?
- How can I make `new[]` default-initialize the array of primitive types?
- 3-byte int and 5-byte long?
- C pointers and arrays/ ‘sizeof’ operator [duplicate]
- What am I not understanding about getline+strings?
- How to copy a .txt file to a char array in c++
- Why sizeof int is wrong, while sizeof(int) is right?
- Braces around string literal in char array declaration valid? (e.g. char s[] = {“Hello World”})
- Is there a way to statically-initialize a dynamically-allocated array in C++?
- how to determine sizeof class with virtual functions?
- C++ concatenate two int arrays into one larger array
- C++: Fastest method to check if all array elements are equal