Question
1. Select the statement that changes the vector v to size 20 Select one: a. resize.v(20); b. resize(v, 20) c. v.resize(20); d. None of the
1. Select the statement that changes the vector v to size 20
Select one:
a. resize.v(20);
b. resize(v, 20)
c. v.resize(20);
d. None of the above
2. Define a two dimensional array of integers named dataVals with 6 rows and 4 columns.
Select one:
a. int dataVals[6][4];
b. int dataVals[6, 4];
c. int dataVals[6+4];
d. int dataVals[6] = int[4];
3.
Which of the following defines an array named nums that stores 15 items of type int?
Select one:
a. int nums[15];
b. int nums[] = 15;
c. int nums = [15];
d. nums = int[15];
4.
Which of the following stores 555 into element number 5 of vector nums?
Select one:
a. vector
b. nums.at(5) = 555;
c. vector
d. nums(5) = 555;
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started