I'm trying to put together a Task to run a pool circulation pump only on the hours when the electricity cost is the lowest. I can get the prices from nordpoolspot.com API. I end up with 24 Doubles, one for each hour of the day. But I have not managed to figure out a way to filter out the lowest values.
For instance I need to run the pump for 6 hours every day. So at every hour I need a way to check "Is this current hour one of the 6 cheapest hours for today?"
Customer support service by UserEcho