How to write a C++ program that allows a user to enter their rating of the three movies in the Dark Knight Trilogy and then display each rating entered, the highest rating, the lowest rating, and the average of the ratings??

Answers

Answer 1

The program is an illustration of arrays.

Arrays are used to hold multiple values in one variable.

The program in C++ where comments are used to explain each line is as follows:

#include <iostream>

using namespace std;

int main(){

   //This declares an array of three elements for the three ratings

   int ratings[3];

   //This initializes the sum of the ratings to 0

   int total = 0;

   //The following iteration gets input for the three ratings

   for(int i = 0; i<3;i++){

       cin>>ratings[i];

       //This calculates the sum of all inputs

       total+=ratings[i];

   }

   //This declares and initializes the lowest and the highest ratings

   int lowest = ratings[0], highest = ratings[0];

   //This iterates through the array

   for(int i = 1; i<3;i++){

       //The following if condition determines the lowest rating

       if (lowest > ratings[i]){    lowest = ratings[i];        }

       //The following if condition determines the highest rating

       if (highest < ratings[i]){            highest = ratings[i];        }

   }

   //This prints the output header

   cout<<"The ratings are: ";

   //The following iteration prints the three ratings

   for(int i = 0; i<3;i++){

       cout<<ratings[i]<<" ";   }

   //The prints the highest ratings

cout<<endl<<"Highest: "<<highest<<endl;

   //The prints the lowest rating

   cout<<"Lowest: "<<lowest<<endl;

   //The prints the average rating

cout<<"Average: "<<total/3<<endl;

   return 0;

}

At the end of the program, the ratings entered, the highest rating, the lowest rating, and the average of the ratings are printed.

See attachment for sample run

Read more about similar programs at:

https://brainly.com/question/13261254

How To Write A C++ Program That Allows A User To Enter Their Rating Of The Three Movies In The Dark Knight

Related Questions

Create a program that: Provides access to a rolodex (list of names and contact information). Have the program accept a name to lookup and that prints the contact information of the matching name. Use an array for names and an array for email address and another array for phone numbers. Make sure that all three arrays contain corresponding information.

Answers

Answer:

Explanation:

The following code is written in Java, it asks the user for a name and looks that name up in the names array. If it finds it prints out all the values in that same index within every array to get the name, email, and phone number. If the name is not found it prints out that the client is not found.

//The code is attached in the text file below and picture shows the output of the working code.

What information will you find in the 16-bit field in an IP datagram?

Answers

Answer: This 16-bit field defines the entire packet size in bytes, including header and data. The minimum size is 20 bytes (header without data) and the maximum is 65,535 bytes. All hosts are required to be able to reassemble datagrams of size up to 576 bytes, but most modern hosts handle much larger packets.

Explanation: Hopefully this helps you with what ever u are doing.

An information which you will find in the 16-bit field in an IP datagram is: the total length of the datagram it's attached to.

An IP address is an abbreviation of internet protocol address and it can be defined as a unique number assigned to a computer or other network devices such as routers, switches, etc., in order to differentiate each device from one another in an active network system. Thus, an IP address is typically used to uniquely identify each computer or network device connected to the internet or an interconnected network.

In Computer networking, IP address are classified into two (2) main categories and these are;

Local (internal) IP address.Global (external) IP address.

An IP datagram can be defined as the standard format of data that an internet protocol (IP) recognizes.

Generally, an IP datagram comprises two (2) main components and these include:

1. The header: it is used for sending messages on a computer to the protocol in the same layer of a destination (recipient) computer.

2. The data: this is a set of information that is transmitted from one computer to another over an interconnected network.

On a related note, an IP datagram contain three (3) fields which are typically used for the transmission of data;

Header length.IP version.Total length.

The Total length is a field that is used to specify the total length of an IP datagram and it is typically 16-bits in size.

In conclusion, an information which is found in the 16-bit field in an IP datagram is the total length of the datagram it's attached to.

Find more information here: https://brainly.com/question/19204809

Aspire is a test you take to prepare for the
A. PSAT
B. SAT
C. ACT
D. FAFSA

Answers

Answer:

ACT

Explanation:

"ACT Aspire is a powerful tool to help students and their parents monitor progress toward a successful ACT test from third grade through tenth grade. The Aspire test assess students' readiness in five areas covered by the ACT test: English, math, reading, science and writing." - https://greentestprep.com/resources/act-prep/act-aspire-test/

Aspire is a test you take to prepare for the ACT. Thus, option C is correct.

What is ACT?

"ACT Aspire is a powerful tool to help students and their parents monitor progress toward a successful ACT test from third grade through tenth grade. The Aspire test assess students' readiness in five areas covered by the ACT test: English, math, reading, science and writing.Aspire is a test people take as a preparation for both ACT a d SAT.

Aspire is a valuable tool to help students and their parents monitor progress towards a good ACT exam from 3rd to 10th grade. The Aspire test assesses student performance in five areas covered by the ACT exam: English, math, reading, science and writing. Aspire Test is offered in the spring and fall seasons, the cost of the assessment tool depends on how many subjects you would like to measure and how often you want your student to be tested.

Learn more about Aspire Test on:

https://brainly.com/question/4469429

#SPJ7

who was the first inventor of computer​

Answers

Answer:

Explanation:

English mathematician and inventor Charles Babbage is credited with having conceived the first automatic digital computer. During the mid-1830s Babbage developed plans for the Analytical Engine.

Answer:

Charles Babage is the first inventor of computer.

9.6 code practice edhesive

Answers

Answer: i got 50% for this I don’t know what to fix

Explanation:

Answer:

def printIt(ar):

   for row in range(len(ar)):

       for col in range(len(ar[0])):

           print(ar[row][col], end=" ")

       print("")

N= []

for r in range(4):

   N.append([])

for r in range(len(N)):

   value = 1

   for c in range(5):

       N[r].append(value)

       value = value +1

printIt(N)

print("")

newValue = 1

for r in range(len(N)):

   for c in range(len(N[0])):

       N[r][c] = newValue

   newValue = newValue + 1

printIt(N)

Explanation: Ez clap

the process of preparing and setting up a software on a computer is called​

Answers

Answer:

installation

Explanation:

Installation (or setup) of a computer program (including device drivers and plugins), is the act of making the program ready for execution.

HELPPPPPP How is does technology impact the career of your choice? Write 5-6 sentences about how technology impacts the career of your choice.

Answers

Answer:

Explanation:

Summary. Technology has had a dramatic impact on the nature of work itself, individual applicants and employees, employers, and career counselors. It has changed the nature of work and the types of jobs that people do today. It has altered the knowledge and skills individuals need to be effective workers.

. What is piracy? ???????????????????​

Answers

Answer: a practice similar to piracy but in other contexts, especially hijacking.

"air piracy"

the unauthorized use or reproduction of another's work.

Explanation:

An array stores data using multiple variable names.

True

False

Answers

Answer: False

Explanation:

It is false that an array stores data using multiple variable names, as it may not as, for starters, an Array cannot store multiple types of variable values. A container object that holds a fixed number of single-type values is known as an array.

What is an array?

A data structure that stores a collection of elements of the same data type under a single variable name is known as an array.

The index number, which is an integer value that represents the element's position within the array, is used to access it.

In other words, an array stores multiple values of the same data type in contiguous memory locations using a single variable name.

For starters, we cannot store multiple types of variable values in an Array. An array is a container object that holds a fixed number of single-type values.

Thus, the given statement is false.

For more details regarding an array, visit:

https://brainly.com/question/19570024

#SPJ3

red + blue =
Red + green =
Magenta - blue =
Yellow - green =
Cyan - blue =​

Answers

Answer:

red + blue is green

red + green is blue

Write a program that computes the sum of squares for a sequence of positive whole numbers. The program asks the user to enter the starting number. Then it asks the user to enter an ending number. It computes the square for each number from the starting number to the ending number. It also calculates the sum of these squares. It displays the numbers, their squares and the sum of the squares.

Answers

Answer:

In Python:

start = int(input("Start: "))

end = int(input("End: "))

total = 0

print("Number\t Squares")

for num in range(start,end+1):

   print(num,"\t",num**2)

   total+=num**2

print("Total: ",total)

Explanation:

This gets the starting number

start = int(input("Start: "))

This gets the ending number

end = int(input("End: "))

This initializes total to 0

total = 0

This prints the header

print("Number\t Squares")

This iterates through start to end

for num in range(start,end+1):

This prints each number and its square

   print(num,"\t",num**2)

This calculates the total squares

   total+=num**2

This prints the calculated total

print("Total: ",total)

PLZZZ HELP
Select the correct answer.
A company utilizes a specific design methodology in the software design process. They utilize concepts of encapsulation in design. Which design methodology would they be using?
A.
structured design
B.
modular design
C.
object-oriented design
D.
rapid application development
E.
use-case design

Answers

Answer:

C is object-oriented design

All of the following are problem-solving steps except:
A. taking action.
B. defining the problem.
c. doing the first solution that comes to mind.
D. creating possible solutions.

Answers

Answer:

C. Doing the first solution that comes to mind.

Explanation:

Lets break this down a bit.

A is a great problem solving step, so we can mark that off.

We can do the same for B.

However, for C, I am hesitant about this one, so I wont mark it off quite yet.

Finally, for D, it is definitely a step, so I can mark that off.

You should never do the first solution that comes to mind, since you haven't done enough brainstorming about other ideas.

Hope this helps!

5) Write a program to read text to end-of-file, and print a count of word lengths, i.e. the total number of words of length 1 which occurred, the number of length 2, and so on. Define a word to be a sequence of alphabetic characters. You should allow for word lengths up to 25 letters. A typical output should be like this: length 1 : 10 occurrences length 2 : 19 occurrences length 3 : 127 occurrences length 4 : 0 occurrences length 5 : 18 occurrences

Answers

Answer:

Explanation:

The following code is written in Python. It is a function that takes in the name of the file to be read and the size of the word. Then the function reads the file, removes whitespace and commas, splits the text into words, and scans the words for all the words that have the same length as the number passed. It counts all those words and prints out the number of occurrences of words of that length.

def countOccurrences(file_name, word_size):

   f = open(file_name, 'r')

   text = f.read()

   text = text.replace(',', '')

   split_text = text.split(' ')

   occurrences = 0

   for word in split_text:

       if len(word) == word_size:

           occurrences += 1

   print("Length 1: " + str(occurrences) + " occurrences")

HELP PLZZZZZZZZ!!!!!!!!!!!

Type the correct answer in the box. Spell all words correctly.
Before a new email application could be released to the public, it was released for a few days to some account holders of a website. The project team then collected feedback from this limited number of users and later made the email application available for public use. What type of testing did the project team use?
The project team used_____________testing for the email application.

Answers

Answer:

Its either business format franchise or business brokers

what is information richness

Answers

Information Richness is the ability of information to change understanding within a time interval.

Hope it helps. Have a great day.

Brainliest would be greatly appreciated.

___________________________________________________________

#SaveTheEarth

#SpreadTheLove

- Mitsu JK

Which option is used to determine whether information that should remain private is included in the final version of a PowerPoint presentation?
Compatibility Check
Grammar Checker
Document Inspector dialog box
Trust Center

Answers

Answer:

Im pretty sure you should put a document inspector dialog box

Answer:

Document Inspector dialog box

Explanation:

edge 2022

"Wake up to reality! Nothing ever goes as planned in this world. The longer you live, the more you realize that in this reality only pain, suffering and futility exist.
Where is this quote from

Answers

Answer:

Naruto Shippuden and from madara uchiha

Explanation:

Answer:

Madara to Obito in Naruto Shippuden after Obito regains conscious from passing out under the rock from the third graet ninja war

Explanation:

Is this correct? I say its B, but my friend says its D.

Answers

The answer is B, best of luck!

Evaluate the following information that shows the projected change in employment from 2014-2024: How can job seekers use the chart? Add data to a résumé and cover letter Gain awareness of how growth trends can impact career plans Research which careers match current skills Talk to community members in a knowledgeable manner You must check the box below prior to submitting your exam! Check this box to indicate you are ready to submit your exam Submit Exam FDK191.10

Answers

Answer:

Answer is B.

Gain awareness of how growth trends can impact career plans

Explanation:

The aim of this activity is to implement an algorithm that returns the union of elements in a collection. Although working with sets is quick and easy in Python, sometimes we might want to find the union between two lists. Create a function called unite_lists, which uses a loop to go through both lists and return common elements. Do not use the built-in set function.

Answers

Answer:

The function in Python is as follows:

def unite_lists(A, B):

   union = []

   for elem in A:

       if elem in B:

           union.append(elem)

   return union

Explanation:

This defines the function

def unite_lists(A, B):

This initializes an empty list for the union list

   union = []

This iterates through list A

   for elem in A:

This checks if the item in list A is in list B

       if elem in B:

If it is present, the item is appended to the union list

           union.append(elem)

This returns the union of the two lists

   return union

Consider the following relation with functional dependencies as shown below.R{sno,sname,age,cno,cname,group}
R(A,B,C,D,E,F)
A-B,C
C-F
D-E
which normal form is the relation R is in?

Answers

Answer:

First Normal Form

Explanation:

The correct answer is - First Normal Form

Reason -

Given that,

A-B,C

C-F

D-E

Here the key is AD

The two partial Functional dependencies are -

A-B,C  

D-E

So,

They are not in Second Normal Form, but they are in First Normal Form.

Click this link to view O*NET’s Work Contexts section for Librarians.

It describes the physical and social elements common to this work. Note that common contexts are listed toward the top, and less common contexts are listed toward the bottom. According to O*NET, what are common work contexts for Librarians? Check all that apply.

face-to-face discussions
pace determined by speed of equipment
cramped work space, awkward positions
indoors, environmentally controlled
telephone and electronic mail
freedom to make decisions

Answers

Answer:

1. b,d,f  2. a,b,c,f  3. b,c,e,f  4. a,c  5. a,b,c,e  6. a,b,c

7. d,e,f  8. a,b,e,f   9. a,c,d  10. b,d,f  11. c,e,f  12. a,c,e,f

Explanation:

all the answers to Finance Workplaces and Tasks Assignment 100%

Answer:

1, 4, 5, 6

Explanation:

the only options that are on the website

Edna needs a safer car to drive. She likes to travel a lot, so she is looking for a small SUV. She is trying to decide between buying a new or used car. After doing some research, she finds out that most cars lose value each year by a process known as depreciation. You may have heard before that a new car loses a large part of its value in the first 2 or 3 years and continues to lose its value, but more gradually, over time. That is because the car does not lose the same amount of value each year, but it loses approximately the same percentage of its value each year. What kind of model would be most useful for calculating the value of a car over time?

Answers

Answer: Buy a new car

Explanation: If its a used car its breaks will be worn out and more likely the breaks will stop working in 6 months and you have to change them. May the forse be with you.

HELPPPPP PLZZZZZZZZZZZZZZZ!!!!!!!!


Select the correct answer.
What type of diagram does the following image depict?


A.
class diagram
B.
deployment diagram
C.
activity diagram
D.
sequence diagram
E.
use case diagram

Answers

Answer:

A

Explanation:

A hope this helped ;)

PLZZ HELP!!!
Select the correct answer.
Brian’s team has built a new application based on the client’s requirements. They will deploy this application in multiple locations on the client side. Brian is unsure about the hardware and software specifications at the client side. Which option will help him best solve this issue?
A.
creating multiple test scripts
B.
automating test scripts
C.
creating multiple test plans
D.
creating multiple test environments
E.
communicating with the development team

Answers

Answer: Option D creating muiltiple test enviroments

Explanation: I had the same question and I hope this helps ( :

The option that will help Brain best solve this issue is by creating multiple test environments.

What is the specification of software?

A software requirements specification (SRS) is known to be a type of requirement that are often written in a document that tells more about what the software can do.

Hence in the above scenario, what will help help Brain best solve this issue is by creating multiple test environments where the client can see a demonstration and be convince in getting the product.

Learn more about application from

https://brainly.com/question/24847617

PLZ HELP!!!

Select the correct answer.
Emma, the quality control manager in a software development company, asks the testing team to check whether the user interface is friendly. To which type of testing is Emma referring?
A.
usability testing
B.
data comparison
C.
validation testing
D.
stress testing
E.
destruction testing

Answers

Answer: A. Usability testing
Explanation:
Usability testing would be the correct answer because if the user interface isn't "frendly" then people won't be able to use it properly. Or if you are refering to the word friendly as looking safe, then even more so would be usability testing. Because if people don't like the fonts and styles of the user interface, they might not use it at all.

Can someone plz answer these questions plz

Answers

Answer:

ñbyte I'm pretty sure, sorry if u get it wrong you should do more research about the question if i get it wrong!!

Draw a data flow diagram that indicates the condition and factors that must be satisfied before a customer request for goods can be granted from a factory

Answers

Skies in here and the beach and

What keys on the keyboard have the ability to move the cursor around on a window?

No links and files or I report!
Will give Brainliest!​

Answers

Answer:

Press the Windows key on your keyboard. In the box that appears, type Ease of Access mouse settings and press Enter . In the Mouse Keys section, toggle the switch under Use numeric pad to move mouse around the screen to On. Press Alt + F4 to exit this menu.

Other Questions
How would an organization minimize the occurrence of groupthink?A. Using a highly authoritative leaderB.hiring the most intelligent applicantsC.giving free rein to diverse opinions D.submitting to public review and scrutiny What is the probability that a randomly selected date in the year 2021 is not in the month of October orNovember?Type your answer into the box as a decimal. Round to the nearest thousandth. I APRECIATE HELP. A regression line was calculated for three similar data sets (A, B, and C) that measure the height of a plant (in inches) over time (in days). The residual plots for each set are shown. Based on the residuals, which data set is best fit by the regression line? Who illustrated the original Percy Jackson and the Olympians cover art?Rick RiordanKwame MbaliaJohn RoccoEric Wilkerson(fre.e points) pls answer c: only put correct answer ty! YOOOO GUYS GUESS WHAT ANOTHER EASY THING WORTH TONS OF POINTS SO ANSWER CORRECTLY THIS IS ONLY WORTH 10 POINTS BUT IM NICE ENOUGH TO SET IT TO 40 (Ill lose 40 youll gain 20) FIND THE VERD PHRASE OF EACH SENTENCE (SOME SENTENCES WILL ONLY HAVE A VERB (4 pictures) rip all my points i only have 49 after this ill have 9 A mobile application is used to display local traffic conditions. Which of the following features of the application best exemplifies the use of crowdsourcing?a. Users can save an address to be used at a later time.b. Users can turn on alerts to be notified about traffic accidents.c. Users can submit updates on local traffic conditions in real time.d. Users can use the application to avoid heavily congested areas. I REALLY NEED HELP ON THIS FAST! The cost of a holiday is 2400. Rana pays a deposit followed by monthly payments, in the ratio deposit:total of the monthly payments=3:5 she makes 6 equal monthly payments. Work out her monthly payment I have to put these in order anybody know how these go ? Suppose the Federal Reserve sets the reserve requirement at 14%, banks hold no excess reserves, and no additional currency is held. Instructions: In part a, round your answer to 1 decimal place. In parts b and c, enter your answers as a whole number. If you are entering a negative number include a minus sign. a. What is the money multiplier A sports store received a shipment of 150 footballs and basketballs. 20% were basketballs. How many footballs were in the shipment? 2. Which of the following statements is accurate regarding a vegetarian diet?All of the essential nutrients can be found in a vegetarian diet.If you decide to switch to a vegetarian diet, you should do so all at once.It is impossible for a vegan-vegetarian to get the recommended amount of proteinVegetarian diets are very unhealthy. Leketa is a secret agent. She needs to send secret messages to her partner, Daniel. Leketa uses the sound waves from the beat of a drum to send her messages. Leketa and Daniel create a secret code using a pattern of drum beats to communicate with one another. In which of the following places would using a drum work to send her secret messages?A. The drum will work on Earth, under the water, and in outer space.B. The drum will work on Earth and under the water. The drum will not work in outer space.C. The drum will work on Earth and in outer space. The drum will not work under the water.D. The drum will work under the water and in outer space. The drum will not work on Earth.Why did you choose your answer to Question 4? Explain in terms of sound waves. QERFEWTDGFSETHWRSTGHBDRAEAGBHSWRTYH What's the best way to find the load capacity of a crane? Select the best option Call the manufacturer Look at the load capacity chart in the cab Ask co-workers It's best determined by lifting a load why is D-Day (june 6,1944) considered a turning poi9nt in world war ii? Find the surface area of the prism You deposit $300 dollars in a savings account the account earns 10% simple interest per year whats the interest after 8 years please help ASAP!!Which of the following is true of castles built during the early Middle Ages?They were built by peasants to house their families.They were constructed mainly out of stone.They were places of refuge for nobles and peasants in time of war.They were difficult to destroy by fire, and therefore many survive to this day.