Assign the size of vector sensorReadings to currentSize.
#include iostream
#include vector
using namespace std;
int main() {
vector int sensorReadings(4);
int currentSize = 0;
sensorReadings.resize(10);
/* Your solution goes here */
cout ""Number of elements: "" currentSize endl;
return 0;
}
コメント