Cold Chain Temperature Anomaly Detection
Cold Chain Temperature Anomaly Detection
HardArrays0% accepted
Vikram monitors cold chain logistics for food delivery across Delhi. Temperature sensors record values at multiple checkpoints. He needs to find delivery routes with the steepest temperature drop (anomaly indicator) to prevent food spoilage.
Approach
Given an array of temperature readings from warehouses to delivery points, find the maximum difference between any two elements where the larger element comes first.
Input
7
8 5 2 4 1 3 6
Output
5
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