News for hackers. Stuff that matters.
Re:How Ruby is beating Python in the battle for the Soul of ... by prolepunk on Monday October 03, 2011 @11:20AM (#3066596)
Not that you can't do this in python:

python -c "print '\n'.join(open('LICENSE.txt','r').read().split('\n')[:-10])"

But this is besides the point.

Re:How Ruby is beating Python in the battle for the Soul of ... by jodrellblank on Monday October 03, 2011 @04:01PM (#3067759)
Your split and join seem redundnant, and open defaults to read-only.

  print open('whatever.file').readlines()[:-10]
But still, don't do that on any log too big to read into memory.