
Computer Networking: A Top-Down Approach (7th Edition)
7th Edition
ISBN: 9780133594140
Author: James Kurose, Keith Ross
Publisher: PEARSON
expand_more
expand_more
format_list_bulleted
Question

Transcribed Image Text:Finding the highest & lowest values in an array. Given the following information: Declare Integer
arraySize = 10 Declare Real numberArray(arraySize = 8.54, 90.41, 8.54, 100, 3, 100.02, 2.99,
44, 100.1, 4.47 Create variables to hold the highest and lowest value, initially set them the value
at the first element in the array. Don't hard code the values, use the array and the subscript. Use
a loop to step through the rest of the elements At each iteration, a comparison is made to the
highest and lowest variable If the element is greater than the highest value, that value is then the
assigned to the highest variable. If the element is lower than the lowest value, that element is
assigned to the lowest variable. Display the highest and lowest numbers found at the end of the
program. If you plan to use Raptor, great, but remember two things. First, Raptor starts their
arrays at 1 not 0. Second, there is no for-loop, so you must use a do until loop with an index
counter.
I have provided a starter raptor file to load the array. Paste pseudocode and flowchart
Remember, your pseudocode and flowchart to match in logic.
Expert Solution

This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
This is a popular solution
Trending nowThis is a popular solution!
Step by stepSolved in 2 steps with 2 images

Knowledge Booster
Similar questions
- 1.Code to _How do you total all of the matching integer elements in an array?. #ASAP..arrow_forwardFinding the highest & lowest values in an array. Given the following information: Declare Integer arraySize = 10 Declare Real numberArray(arraySize = 8.54, 90.41, 8.54, 100, 3, 100.02, 2.99, 44, 100.1, 4.47 Create variables to hold the highest and lowest value, initially set them the value at the first element in the array. Don't hard code the values, use the array and the subscript. Use a loop to step through the rest of the elements At each iteration, a comparison is made to the highest and lowest variable If the element is greater than the highest value, that value is then the assigned to the highest variable. If the element is lower than the lowest value, that element is assigned to the lowest variable. Display the highest and lowest numbers found at the end of the program. If you plan to use Raptor, great, but remember two things. First, Raptor starts their arrays at 1 not 0. Second, there is no for-loop, so you must use a do until loop with an index counter. I have provided a…arrow_forwardSum values - Method, property, both (please answer which one) can you sum values of a numpy array via a method function or through its attributes only or botharrow_forward
- The intNum array is declared as follows: Dim intNum(,) As Integer = {{6, 12, 9, 5, 2}, {35, 60, 17, 8, 10}}. The intNum(1, 4) = intNum(1, 2) - 5 statement will _____________________. a. replace the 10 amount with 12 b. replace the 5 amount with 7 c. replace the 2 amount with 4 d. None of the above.arrow_forwardWhen using two loops to traverse an array, you can use the For...Next statement to code the outer loop and use the For Each...Next statement to code the nested loop. True or False?arrow_forwardThe logic will allow the user to: Load a single dimensional array of size 50 with a random number The random number will range from 1 to 1,000 (you may have duplicate values) Find the highest value and the index location that it was in Find the smallest value and the index location that it was in Display the array’s contents. Display the highest value and its index location Display the lowest value and its index location Allow the user to execute this application multiple times (some sort of loop?) You will need one for loop to load the array as well as one or two for loops to search that array. The rand also has a “nasty” tendency to create the same results repeatedly in an exe. To avoid that, we have to “shuffle the deck” every time. This ensures that all numbers are an equal probability of appearing and not the same set of values (would create a boring game). // Add this to "shuffle the deck" every time to ensure that // different values could occur else the exe produces the…arrow_forward
- In visual basic Create an array that will hold 10 integer values.arrow_forwardTicTacToeCreate the board display the board Set token to ‘x’Loop //at most 9 times, but end loop when someone wins{ Ask player where to place token display the board Checks if won Change token (if it was ‘x’ change to ‘o’ and vice versa)}Either congratulate someone on winning or say it was a draw. Create a 17x17 array of characters and put ‘ ‘ in each element.2. Write a loop to make the first horizontal line, and another to do the second horizontal line3. Write a loop to make the first vertical line, and another to create the second vertical line4. Put in the numbers (this is so the player can choose where to put the token). You will need 9 separate assignment statements.arrow_forward5 نقاط Q1. Write a code to find the summation of all numbers that are less than or equal to 10 in the array. C= {-10, 35, 10, -5, 6, 16, -23, 94, -22, 12, 202, -52O, 0, .-3}arrow_forward
- Visual basic 6.0arrow_forwardAlert dont submit AI generated answer.arrow_forwardpart a- 2point) for 3 students find the average of a student by asking him how many grades do you have. The answer to this question, determine the size of the array(list of grades) and then ask the user to enter grades(the number of the grades is equal to the size of the array) then calculate the average for each student. Hence, you will calculate 3 averages. to calculate the average, use the array accumulator. Also when you get each grade validate it. validation for grade means that you check whether a grade is between 0 and 100. if the grade is negative or a grade is more than 100 then it is not valid and you have to ask the user to enter a grade again. Part b- 1 point) Find the maximum and minimum grades for each student. Part c- 1 point) Print the sorted list of the grades for each student. example: if grades user entered are: 60 78 98 23 45 then sorted list is:23 45 60 78 98 (Array not vector)arrow_forward
arrow_back_ios
SEE MORE QUESTIONS
arrow_forward_ios
Recommended textbooks for you
- Computer Networking: A Top-Down Approach (7th Edi...Computer EngineeringISBN:9780133594140Author:James Kurose, Keith RossPublisher:PEARSONComputer Organization and Design MIPS Edition, Fi...Computer EngineeringISBN:9780124077263Author:David A. Patterson, John L. HennessyPublisher:Elsevier ScienceNetwork+ Guide to Networks (MindTap Course List)Computer EngineeringISBN:9781337569330Author:Jill West, Tamara Dean, Jean AndrewsPublisher:Cengage Learning
- Concepts of Database ManagementComputer EngineeringISBN:9781337093422Author:Joy L. Starks, Philip J. Pratt, Mary Z. LastPublisher:Cengage LearningPrelude to ProgrammingComputer EngineeringISBN:9780133750423Author:VENIT, StewartPublisher:Pearson EducationSc Business Data Communications and Networking, T...Computer EngineeringISBN:9781119368830Author:FITZGERALDPublisher:WILEY

Computer Networking: A Top-Down Approach (7th Edi...
Computer Engineering
ISBN:9780133594140
Author:James Kurose, Keith Ross
Publisher:PEARSON

Computer Organization and Design MIPS Edition, Fi...
Computer Engineering
ISBN:9780124077263
Author:David A. Patterson, John L. Hennessy
Publisher:Elsevier Science

Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:9781337569330
Author:Jill West, Tamara Dean, Jean Andrews
Publisher:Cengage Learning

Concepts of Database Management
Computer Engineering
ISBN:9781337093422
Author:Joy L. Starks, Philip J. Pratt, Mary Z. Last
Publisher:Cengage Learning

Prelude to Programming
Computer Engineering
ISBN:9780133750423
Author:VENIT, Stewart
Publisher:Pearson Education

Sc Business Data Communications and Networking, T...
Computer Engineering
ISBN:9781119368830
Author:FITZGERALD
Publisher:WILEY