Answer to Question #263374 in Algorithms for Dharani

Question #263374

Build a pseudocode for scenario an MCQ Assignment sheet of Descriptive Statistics to finish before tomorrow morning. the sheet only includes only 1 type of Question but with Different data fields in each question.




Question - Distance of top of bars from X-axis is given to you. Plot the Graph for given data and find the Volume of Graph that can be filled with any fluid.




You don't want to do the same calculation so many times since you're short on time. So you decide to write an algorithm that calculates the Volume of a graph.




Note - Assume an elevetion Graph where width of each bar is 1.

1
Expert's answer
2021-11-09T17:46:32-0500

Start

Input:

Deadline \\ tomorrow morning

Question: 'Distance of top of bars from X-axis is given to you. Plot the Graph for given data and find the Volume of Graph that can be filled with any fluid'.

Input

array d(n) \\ Distance of top of bars from X-axis

w=1 \\ width of each bar

V=0 \\ initial volume

for i from 1 to n \\Calculate the Volume of a graph

"V=V+2\\pi d"[i]

Output:

V \\Volume

End


Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS