Chief Hopper Discussions | | HackerRank

Chief Hopper

  • + 0 comments

    Python

    def chiefHopper(arr):
        energy = 0
        for a in arr[::-1]:
            energy = math.ceil((energy + a)/2)
        return energy