Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Complete the following program with appropriate C++ statements. This program stores the information of 40 students using structures. Declare a structure to represent mark with

Complete the following program with appropriate C++ statements. This program stores the information of 40 students using structures. Declare a structure to represent mark with two (2) members of type float; carry marks and f i n a l e x a m. Then, create a structure named Student with three (3) members. The members include ID of type char array with size 10, name of type char array with size 40, and subject of type Mark. Store 40 input data in an array named stdn of type Student . Print out a list of students who pass the subject ((carry marks plus f i n a l e x a m is 50 or more). Note: Please write C ++ statements WITHOUT blank spaces unless it is absolutely needed. Example: int num,a,b;

Trace the following program segment. Write the elements of each array after the execution of the statement(s) in Table 1.

1 2 3 4 5 6 7 8 9 10 11
int bil[3]={1,2}, color2D[3][3]={{10,12},{6},8,9,5}; int i, j, x = 1; for(i = 0; i < 3; i++) {  for(j = 2; j > 0; j--)  color2D[i][j] = color2D[i][j] + bil[i] + 1;  bil[i] = color2D[i][i]; }  bil[2] = bil[x++]; bil[1] = ++color2D[x][x-1]; bil[0] = bil[x]++ - color2D[1][0];

Table 1

Line

Array bil

Array color2D

1

[0]

[1]

[2]

1

2

0

[0]

[1]

[2]

[0]

Answer

Answer

Answer

[1]

Answer

Answer

Answer

[2]

Answer

Answer

Answer

3-7

[0]

[1]

[2]

Answer

Answer

Answer

[0]

[1]

[2]

[0]

Answer

Answer

Answer

[1]

Answer

Answer

Answer

[2]

Answer

Answer

Answer

9

[0]

[1]

[2]

Answer

Answer

Answer

10

[0]

[1]

[2]

Answer

Answer

Answer

11

[0]

[1]

[2]

Answer

Answer

Answer

Please answer all parts of the question.

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

Concepts of Database Management

Authors: Philip J. Pratt, Joseph J. Adamski

7th edition

978-1111825911, 1111825912, 978-1133684374, 1133684378, 978-111182591

More Books

Students also viewed these Databases questions