C++ for Engineers and Scientists
4th Edition
ISBN: 9781133187844
Author: Bronson, Gary J.
Publisher: Course Technology Ptr
expand_more
expand_more
format_list_bulleted
Textbook Question
Chapter 7.3, Problem 1E
(Practice) Write specification statements for the following:
a. An array of integers with 6 rows and 10 columns
b. An array of integers with 2 rows and 5 columns
c. An array of characters with 7 rows and 12 columns
d. An array of characters with 15 rows and 7 columns
e. An array of double-precision numbers with 10 rows and 25 columns
f. An array of double-precision numbers with 16 rows and 8 columns
Expert Solution & Answer
Trending nowThis is a popular solution!
Students have asked these similar questions
(C++) PLEASE INCLUDE COMMENTS AND OUTPUT SCREEN
Write a program that will do the following:
In main, declare an array of size 20 and name it "randomArray." Use the function in step 2 to fill the array. Use the function in step 3 to print the array.
Create a function that generates 20 random integers with a range of 1 to 10 and places them into an array. Re-cycle the functions from Lab 10 where appropriate.
Make this a function.
There will be two arguments in the parameter list of this function: an array and the size of the array.
Within the function and the function prototype name the array: intArray.
Within the function and the function prototype name the size of the array: size.
The data type of the function will be void since the array will be sent back through the parameter list.
Bring in the function that generates and returns a random number that you created from the previous module. Call that function from this within the loop that adds random numbers to the…
(JAVA)
Create a two-dimensional array of type double to contain the three different SD Marks (JD521, PRG521, and IP521) for six different students. A single array of type String must be used to store the student names (Maxwell, Carl, Gerhard, Paul, James, and Cena).
Allow a user to enter in a number, ranging from 1 to 6, which will represent the student position in the table MCSD max and present the marks for each respecting module. The program can only stop when the user enter a number greater than 6.
Printout the student name including the JD521, PRG521, and IP521 max, the total of marks and the average of all marks. Use a condition statement to decide that the student has passed or not (Pass rate is 70).
The programming language is java
Student name
JD521
PRG521
IPG521
Maxwell
80
65
70
Carl
95
70
65
Gerhard
87
80
73
Paul
65
45
60
James
45
87
65
Use C language
Chapter 7 Solutions
C++ for Engineers and Scientists
Ch. 7.1 - (Practice) Write array declarations for the...Ch. 7.1 - (Practice) Write correct notation for the first,...Ch. 7.1 - Prob. 3ECh. 7.1 - (Practice) a. Write output statements using cout...Ch. 7.1 - (Desk check) List the elements displayed by the...Ch. 7.1 - (Practice) a. Write a program to input the...Ch. 7.1 - (Practice) Write a program to input eight integer...Ch. 7.1 - (Data processing) a. Write a program to input 10...Ch. 7.1 - Prob. 9ECh. 7.1 - (Electrical eng.) Write a program that specifies...
Ch. 7.2 - (Practice) Write array declarations, including...Ch. 7.2 - (Data processing) Write an array declaration...Ch. 7.2 - (Data processing) Write a program that uses an...Ch. 7.2 - (Electrical eng.) Write a program that stores the...Ch. 7.2 - (Practice) a. Write a declaration to store the...Ch. 7.3 - (Practice) Write specification statements for the...Ch. 7.3 - (Desk check) Determine the output produced by the...Ch. 7.3 - (Practice) a. Write a C++ program that adds the...Ch. 7.3 - (Practice) Write a C++ program that adds...Ch. 7.3 - Prob. 5ECh. 7.3 - (Electrical eng.) a. An engineer has constructed a...Ch. 7.4 - Prob. 1ECh. 7.4 - Prob. 2ECh. 7.4 - Prob. 3ECh. 7.4 - Prob. 4ECh. 7.4 - Prob. 5ECh. 7.4 - (Electrical eng.) Write a program that declares...Ch. 7.4 - (Statistics) Write a program that includes two...Ch. 7.5 - Prob. 1ECh. 7.5 - (Practice) Run Program 7.10 to determine the...Ch. 7.5 - Prob. 3ECh. 7.5 - (List maintenance) a. Write a complete C++ program...Ch. 7.5 - Prob. 5ECh. 7.5 - (List maintenance) The following letters are...Ch. 7.5 - (File creation) Write a C++ program that creates...Ch. 7.5 - Prob. 8ECh. 7.5 - Prob. 9ECh. 7.5 - Prob. 10ECh. 7.5 - Prob. 11ECh. 7.5 - Prob. 12ECh. 7.5 - Prob. 13ECh. 7.5 - Prob. 14ECh. 7.5 - Prob. 15ECh. 7.6 - Prob. 1ECh. 7.6 - Prob. 2ECh. 7.6 - Prob. 3ECh. 7.6 - Prob. 4ECh. 7.6 - Prob. 5ECh. 7.6 - Prob. 6ECh. 7.6 - Prob. 7ECh. 7.6 - Prob. 8ECh. 7.6 - (Practice) Use the max_element and min_element...Ch. 7 - (Statistics) a. Write a C++ program that reads a...Ch. 7 - (Practice) Define an array named peopleTypes that...Ch. 7 - (Numerical) Given a one-dimensional array of...Ch. 7 - (Numerical) Write and test a function that returns...Ch. 7 - (Sorting) Read a set of numerical grades from the...Ch. 7 - (Numerical) a. Define an array with a maximum of...Ch. 7 - (Numerical) Using the srand() and rand() C++...Ch. 7 - (Statistical) In many statistical analysis...Ch. 7 - (Data processing) Your professor has asked you to...Ch. 7 - (Modify) Modify the program written for Exercise 9...Ch. 7 - Prob. 11PPCh. 7 - (Data processing) The answers to a true-false test...Ch. 7 - Prob. 13PPCh. 7 - (Data processing) Construct a three-dimensional...Ch. 7 - (Computation) A magic square is a square of...Ch. 7 - (Computation) Among other applications, Pascal’s...
Knowledge Booster
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.Similar questions
- A. Define the following arrays: i. empNum, a 100-element array of ints ii. payRate, a 25-element array of doubles iii. miles, a 14-element array of floats iv. letter, a 26-element array of chars v. lightYears, a 1,000-element array of doubles B. Write a function definition with three float parameter, n1, n2, n3 and returns the product of the three parameters. The name of the function should be findProduct. C. Write a function prototype with three integer parameters, value1, value2, value3 without a return type and with a name showValue.arrow_forward(C PROGRAMMING ONLY) 1. Spell-it-out!by CodeChum Admin Are you intimidated with complicated words? Don't be! The trick is to break it down letter by letter! Let’s create a program that prints out the character in the array index indicated by the input integer. For example, if the array has 3 character elements, 'j', 'r', and 'd', and the inputted integer value is 1, then we print 'r' because 'r' is found at index 1. Instructions: In the code editor, you are provided with an array of characters (or a string).Your task is to ask the user for an integer input which represents the index and then print out the character of the string found at that index.Input 1. Index of the array Output Enter the index: 4rarrow_forward(in java) (with a screenshot of the code please) write a java program that contains 2 arrays, one for 10 students names and the other for their grades they must be all entered by the user -the names array will be a 1d array (single array) -the grades array will be a 2d array and it will have 3 rows and 10 columns, the first one is will represent the first exam, the second will represent the second exam, and the third one will represent the final exam finally, you will do a loop that will calculate the sum of all exams for each studentarrow_forward
- can you solve this by using C++, Thanks!arrow_forward- come up with test case - make sure the code works - use java languagearrow_forward(CAN YOU MAKE LESS FUNTIONS AND DO IT SIMPLE AND UNIQUE? PLEASE. THANK YOU ) PROGRAM IN C++ Odette's typhoon-related casualties. Create an array-based program that accepts the following data: the names of typhoon Odette victims, their ages, and their current status (A – alive, D – deceased, I – wounded, and M – missing). Your arrays should be proportionate to the barangay's expected population. Enter the barangay's name and the typhoon's projected total population. Following data entry, show the following information about each person according to their name - their name (in alphabetical order), their condition, the number of individuals who survived, died, were injured, or went missing, as well as their proportion of the total population. An Earthquake's Accident CODE OUTPUT : Barangay Name:____ Estimated NO. of residents:________ Name:____ Age:__ (A – alive, D – deceased, I – wounded, and M – missing)___ Additional Entry (Y/N)? Y…arrow_forward
- Need fun Language code please. The Programs:- (File: count.fun) Write a program which counts from 1 to 10, printing each number on a line by itself. (File: array.fun) For this program you have two requirements: Create a function which takes two arguments, an array and the number of elements in the array. Have this function print the contents of the array, one entry per line. Have the program read in an array of 10 numbers. Next, reverse the contents of the array. Finally have your program print out the contents of the array, one per line.arrow_forward(Check test scores) The answers to a true-false test are as follows: T T F F T. Given a two-dimensional answer array, in which each row corresponds to the answers provided on one test, write a function that accepts the two-dimensional array and number of tests as parameters and returns a one-dimensional array containing the grades for each test. (Each question is worth 5 points so that the maximum possible grade is 25.) Test your function with the following data: int score = 0;arrow_forward(Evaluation of Trainees) Use a two-dimensional array to solve the following problem: A company has four trainees (1 to 4) who take five different programs (1 to 5). Once a week, the trainer creates evaluation results for each program taken. Each result contains the following: a. The trainee number b. The program number c. The score of that program taken that week (0 to 10 scores) Thus, the trainer creates 5 results per week for each trainee. Assume that the information from all the results for last month is available. Write an application that will read all this information for last month’s results and summarize the total scores by the trainee and by the program. All totals should be stored in the two-dimensional array. After processing all the information for last month, display the results in tabular format, with each column representing a trainee an each row representing a particular program. Average each row to get the average scores of each program for last month.…arrow_forward
- A function has different forms such as function call ,declaration, definition .in your opinion which form of function is called prototype and why?arrow_forward(C PROGRAMMING ONLY) 5. Sum of My Winningsby CodeChum Admin I've joined a lot of programming competitions and since I've been learning programming in CodeChum, I won a lot of them! But now, since I'm tired, I need your help to count all of my winnings. Can you help me please? I promise to share some of it with you. Instructions: In the code editor, you are provided with an array which contains 100 elements.Your task is to compute and print the sum of all of the elements. Output Total = 100arrow_forward(Airplane Seating Assignment) | Write a program that can be used to assign seats for a commercial airplane. The airplane has 13 rows, with six seats in each row. Rows 1 and 2 are first class, rows 3 through 7 are business class, and rows 8 through 13 are economy class. Use two parallel arrays: a one-dimensional array to store the row number of the seats (Row #) a two-dimensional array of 13 rows and 6 columns to store the seat assignments (*) and seat letters (A-F) Your program must prompt the user to enter the following information: Reserve a seat (Yes (Y/y) or No (N/n)) Assign ticket type (first class (F/f), business class (B/b), or economy class (E/e)) Select desired seat (1-13 and A-F) Your program must contain at least the following functions: a function to initialize the seat plan. a function to show the seat assignments. a function to show the menu to assign a seat. a function to assign and select your desired seat. a function for each ticket type that determines if a seat…arrow_forward
arrow_back_ios
SEE MORE QUESTIONS
arrow_forward_ios
Recommended textbooks for you
- C++ for Engineers and ScientistsComputer ScienceISBN:9781133187844Author:Bronson, Gary J.Publisher:Course Technology Ptr
C++ for Engineers and Scientists
Computer Science
ISBN:9781133187844
Author:Bronson, Gary J.
Publisher:Course Technology Ptr
Boolean Algebra - Digital Logic and Logic Families - Industrial Electronics; Author: Ekeeda;https://www.youtube.com/watch?v=u7XnJos-_Hs;License: Standard YouTube License, CC-BY
Boolean Algebra 1 – The Laws of Boolean Algebra; Author: Computer Science;https://www.youtube.com/watch?v=EPJf4owqwdA;License: Standard Youtube License