Parsing logs.. just can't figure it out
<p>Alright, so I'm supposed to make a script that parses all the chat logs from irc channels, combine the ones that match names, and then sort the chat logs by date.</p>

<p>This is an example chat log:</p>

<pre><code>    jul 29 19:20:53 &lt;lol&gt; lolfile3
    jul 31 19:20:53 &lt;lol&gt; lolfile3321
    aug 1 19:20:53 &lt;lol&gt; lolfile31324
    jul 30 19:20:53 &lt;lol&gt; lolfile32
</code></pre>

<p>I need to order them by the timestamp (jul 30 19:20:53) however I've been trying for hours on end but to no avail. </p>

<p>Here's the code I already have (this is file merging, file writing and everything. The timestamp is the last thing I need to do!)</p>

<p>I couldn't figure out how to add code to my question so I link you to pastebin:
<a href="http://pastebin.com/2VrSRZZr" rel="nofollow">http://pastebin.com/2VrSRZZr</a></p>

<p>Thank you so much if you could help me by posting code. Obviously I don't expect to be spoonfed but some code would be nice.</p>
