Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

1. Write the statement to declare and initialize a one-dimensional int array named scores that has 10 elements. Then write the statement to store the

1. Write the statement to declare and initialize a one-dimensional int array named scores that has 10 elements. Then write the statement to store the number 12 in the third element of the array. ______________________________________________________________________________

2. Write the code to display the contents of the scores array from number 1 above. Use the for statement with a counter variable named x. _______________________________________________________________________

3. What will the resulting output show if I try to print out the values of the array called names by using the statement cout << names << endl;

_______________________________________

4. Write a single line of code to assign the value 1.67 to element 9 of array temp. _______________________________________

5. What is the value of num[3] Given the statements num[9] = 40

num[4] = 37

num[3] = num[9] num[4];

______________________________________________________________________________

6. Type a line of code that would assign the value of 89.75 to row number seven and column number five of a two-dimensional array named prices. _________________________________________________________________________

7. Suppose that I have the statements;

Char facultyName[25];

Char staffName[20];

Char yourName[20];

What would be the effect of me using the following statements.

Strcpy(facultyName, Keith Bond);

Strcpy(staffName, John Doe);

Strcpy(yourName, staffName);

________________________________________________________________________________

8. Please give me a definition/description of parallel arrays.

________________________________________________________________________________

9. Please initialize the two-dimensional array called wonder with four rows and four columns with the following rows of data as you are declaring it.

Components of the first row are 4, 6, 8, 10; the components of the second row are 44, 11, 4, 25; the components of the third row are 33, 20, 48, 29; and the components of the fourth row are 63, 17, 105, 57.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Professional IPhone And IPad Database Application Programming

Authors: Patrick Alessi

1st Edition

0470636173, 978-0470636176

More Books

Students also viewed these Databases questions