BESCOM Peak Consumption Hour Identifier
BESCOM Peak Consumption Hour Identifier
EasyArrays0% accepted
Ravi received his Bangalore electricity bill from BESCOM showing hourly power consumption. The array contains consumption in units for each hour of the day. Find which hour had the maximum consumption so Ravi can shift appliance usage to off-peak times.
Approach
Given array of N hourly consumption values, find the hour index with maximum consumption.
Input
consumption=[5,10,8,15,12,7,9]
Output
3
More Arrays problems
Browse all coding problems →solution.py
Loading editor...
Test 1
Test 2
Test 3
Press Run to test your custom input, or Submit to judge against all test cases.
Sign in to continue
Create a free account to run code, submit solutions and track progress.
- Free forever — no credit card
- 10+ languages with live execution
- Points, streaks & leaderboards