pls help Write a flowchart that determines whether a meeting room is in violation of fire law regulations regarding the maximum room capacity. The program will read in the maximum room capacity and the number of people to attend the meeting. If the number of people is less than or equal to the maximum room capacity, the program announces that it is legal to hold the meeting and tells how many additional people may legally attend. If the number of people exceeds the maximum room capacity, the program announces that the meeting cannot be held as planned due to fire regulations and tells how man
You already did most of the work. Just break it down sentence by sentence. First input for capacity and number of people. Then check which of the two is greater. From here you have two branches. One branch is if the number of people is greater than the capacity, and the other is if the number of people is not greater than the capacity. In each respective branch, you output a statement and state the difference.
@m_duran i'm not sure if i should represent the capacity and number of people with variables like x and y or a and b. is it okay?
@zaisav yes you can represent variables for capacity and number and you need it ... it will be easy if you take variable name more easier like for capacity = cap and people = pN > people no.... try like this... and um agree with @m_duran
It is a good habit to name your variables, functions, etc. something that is descriptive of what its purpose is. It makes your code a lot easier to read for others and also for yourself when you come back to it later on.
Join our real-time social learning platform and learn together with your friends!