Question: Let's play Holi Max. score: 110 Dnana is very eager to celebrate any festival. He goes through his calender and found that next month there

 Let's play Holi Max. score: 110 Dnana is very eager to

Let's play Holi Max. score: 110 Dnana is very eager to celebrate any festival. He goes through his calender and found that next month there is holi. For holi he is thinking to do something different. But without your help he can't do anything because he is not good in studies. Help Dnana and celebrate holi with Dnana. If you help Dnana then Dnana will give you 110 point for this contest. This holi Dnana is going to fence all his building with light. You are given an array of height and you have to find the length of light required to fence all the building. In other words : You have to find the perimeter of the shape formed by the building having heights given in the form of the array. Given that all the building are adjecent to each other and width of 1 building is 1 unit and height of h(i) unit for ith building. Such that you have to cover the border of building or find the perimeter of building. size of Array

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!