Design a raptor program that uses an array to store 5


Part 1: Raptor Arrays

Here is a very short introduction to arrays using RAPTOR (also included in the Activity folder): https://web.cerritos.edu/jwilson/SitePages/cis_103/presentations/Arrays%20in%20RAPTOR.pdf

Here is a more comprehensive explanation of RAPTOR arrays (also included in the Activity folder):
https://www.google.com/url?sa=t&rct=j&q=&esrc=s&source=web&cd=1&ved=0CB0QFjAAahUKEwjTz9PHmZbIAhVDmoAKHXqDAcM&url=http%3A%2F%2Fraptor.martincarlisle.com%2FG-Arrays.doc&usg=AFQjCNF7pEwSqNgcJfm9yS0RNTsfiytIuw&bvm=bv.103388427,d.eXY

In this handout, focus on the sections and examples discussing one-dimensional arrays. We will cover multi-dimensional arrays in Chapter 8. The section "Processing Array Variables Using Loops" has several good examples of processing arrays including: assigning values to an array variable, reading values into an array, writing array variable values out, totaling and computing the average of the values in an array, finding the largest value of all the values in an array, and finding the index of the largest value in an array.

After reading the above documentation, view the YouTube video RAPTOR21 - Introduction to Arrays by Brad Yourth: https://www.youtube.com/watch?v=kaSY1aT2zqw
Next, view the YouTube video RAPTOR22 - Arrays2 by Brad Yourth:https://www.youtube.com/watch?v=IRZumD0jQAE

The most important things to note about RAPTOR arrays is that they can be created dynamically. In other words, there is no formal declaration statement - you just start using them. Also, RAPTOR array indexing starts at 1 instead of 0. The first element in the array is at subscript [1] instead of [0].

Part 2: Displaying an array's values in reverse order

Design a Raptor program that uses an array to store 5 values entered by the user and then displays the numbers in reverse order. Use two loops: one for reading the user entered values into the array; and another for displaying the contents of the array in reverse order. Hint: the secondloop will use a counter that starts at the size (length) of the array, and is then decremented by 1 each pass of the loop(for example: counter = counter - 1).

Example output:

Enter a number: 34
Enter a number: 12
Enter a number: 8
Enter a number: 56
Enter a number: 25
25
56
8
12
34

Save a screen capture of the Raptor flowchart and a screen capture of the Master Console displaying an example run of the program. You might need to do two separate screen captures - one of the flowchart and one of the Master Console.

[ Insert the screen capture of your Raptor program with at least one example run]

Part 3: Finding the maximum value in an array

Design a Raptor program that uses an array called fmax to store 10 positive values entered by the user. Determine the maximum value entered and display it to the screen. The second handout has a similar example using the Section_GPA array which already contains values.

Hints: Use a loop with a nested if statement (decision structure).
Do not use the variable name ‘max', it is the name of a function in Raptor.

Example output:

Enter a number: 34
Enter a number: 23
Enter a number: 98
Enter a number: 56
Enter a number: 13
Enter a number: 5
Enter a number: 10
Enter a number: 49
Enter a number: 33
Enter a number: 76
The maximum value in the array is 98

Save a screen capture of the Raptor flowchart and a screen capture of the Master Console displaying at least one run.

Solution Preview :

Prepared by a verified Expert
Computer Engineering: Design a raptor program that uses an array to store 5
Reference No:- TGS01134633

Now Priced at $60 (50% Discount)

Recommended (91%)

Rated (4.3/5)