Why not submit it?
Of course, you'd better check it first, since it doesn't actually work.
EDIT: Ah - I see you've edited it, but without saying you've done so. It still doesn't work.
EDIT2: It's also bad form to put code here when others might want the challenge of trying it themselves.