Sum Keys in Array And Map Against A 24 Hour Structure
<p>I'm having the following problem and quite frankly no idea how to solve it:</p>

<p>Each array has a numeric value in key[0] and a time in key[1]. My goal is to map this output against a 24 hour period. </p>

<p>Sum all key[0] values where key[1] time is between 00:00 - 01:00, 01:00 - 02:00, etc.</p>

<p>If there are no values in a certain time period, "0" should be printed. </p>

<p>Here are the arrays that hold the values:</p>

<pre><code>Array ( 

[4045862944400] =&gt; Array ( 
[0] =&gt; 192 
[1] =&gt; 23:52 
) 
[403274909688162] =&gt; Array ( 
[0] =&gt; 186 
[1] =&gt; 22:21 
) 
[402735273075459] =&gt; Array ( 
[0] =&gt; 311 
[1] =&gt; 04:29 
) 
[252948031457462] =&gt; Array ( 
[0] =&gt; 385 
[1] =&gt; 06:22 
) 
[400606749954978] =&gt; Array ( 
[0] =&gt; 287 
[1] =&gt; 05:01 
) 
[286755318061725] =&gt; Array ( 
[0] =&gt; 358 
[1] =&gt; 04:51 
) 
[399687880046865] =&gt; Array ( 
[0] =&gt; 257 
[1] =&gt; 21:51 
) 
[398332190182434] =&gt; Array ( 
[0] =&gt; 240 
[1] =&gt; 23:19 
) 
[397768486905471] =&gt; Array ( 
[0] =&gt; 311 
[1] =&gt; 05:38 
) 
[396907650324888] =&gt; Array ( 
[0] =&gt; 293 
[1] =&gt; 03:38 
) 
[394850557197264] =&gt; Array ( 
[0] =&gt; 496 
[1] =&gt; 05:12 
) 
[394121230603530] =&gt; Array ( 
[0] =&gt; 475 
[1] =&gt; 04:15 
) 
[69757766367627] =&gt; Array ( 
[0] =&gt; 488 
[1] =&gt; 04:01 
) 
[391602517522068] =&gt; Array ( 
[0] =&gt; 506 
[1] =&gt; 03:44 
) 
[390848830930770] =&gt; Array ( 
[0] =&gt; 437 
[1] =&gt; 06:05 
) 
[389975351018118] =&gt; Array ( 
[0] =&gt; 452 
[1] =&gt; 04:00 
) 
[242486689170043] =&gt; Array ( 
[0] =&gt; 525 
[1] =&gt; 04:13 
) 
[388151047867215] =&gt; Array ( 
[0] =&gt; 415 
[1] =&gt; 00:22 
) 
[387476447934675] =&gt; Array ( 
[0] =&gt; 502 
[1] =&gt; 04:51 
) 
[386620518020268] =&gt; Array ( 
[0] =&gt; 467 
[1] =&gt; 06:05 
) 
[215937481836499] =&gt; Array ( 
[0] =&gt; 359 
[1] =&gt; 01:10 
) )
</code></pre>

<p>The output should be an array that represents 24 hours and has the according sum of values for each hour.</p>
