Computer Science, asked by yerramakhil3, 2 months ago

Question 1
Max. score: 5000
Garden Fence
Kirti and her friends are walking along the H-height boundary wall, and there is a security guard next to the wall. They don't want them to be seen
by the guard. To do this, anyone's height should not exceed H. When anyone with a height greater than H, he or she must bent down so that the
guard does not see them. The heights of each person are given to you.
Consider the width of the person walking upright to be equal to 1, while the width of the person who is bent is equal to 2. While walking, friends
want to talk to each other, so they want to be as close as possible and walk next to each other. What is the required road width, so that friends can
walk next to each other and the guard cannot see them?
Function Description
Complete the roadDistance function in the editor below. It has the following parameter(s):
Parameters
Name
Type
A
Description
N
INTEGER
Number of persons
heights
INTEGER ARRAY
Height of each person
H
INTEGER
Height of boundary wall
103
Q ENG​

Answers

Answered by raminderdeepsinghdhi
0

Answer:

the answer of questions is 3 feeet

Similar questions