Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Problem 6.9 In C language, Consider a 5-by-20 integer array grades: a) Write a declaration for grades. b) How many rows does the array have?

Problem 6.9

In C language,

Consider a 5-by-20 integer array grades:

a) Write a declaration for grades.

b) How many rows does the array have?

c) How many columns does the array have?

d) How many elements does the array have?

e) Write the names of all elements in the first column of the array.

f) Write the name of the element in the third row and second column of the array.

g) Write a single statement to assign the value 100 to the element in the first row and second column.

h) Write a nested loop to get all the elements from the keyboard.

i) Write a nested for statement to initialize all elements to zero.

j) Write a statement that copies the values from an array double mathGrades[20] into the elements of the first row of grades.

k) Write a series of statements that determine and print the highest value in the first row of grades.

l) Write a statement to display the element in column 2 of the array.

m) Write a statement to calculate the average of the elements in the first row.

n) Write a series of statements that prints the array grades in a tabular format. List the column subscripts as headings across the top and list the row subscripts at the left of each row.

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

Distributed Relational Database Architecture Connectivity Guide

Authors: Teresa Hopper

4th Edition

0133983064, 978-0133983067

More Books

Students also viewed these Databases questions