Snow Leopard on it.
http://computers.tutsplus.com/tutorials/how-to-create-a-bootable-usb-drive-with-os-x-snow-leopard--cms-21491
That was easy. Read ALL the comments.
As for removing the CD, I have a couple of questions.
1. Is there any noise coming from the optical drive when the eject key is pressed?
2. Have you tried holding the the iMac up with its right side (slot side) facing downward, pressing the eject key and shaking the iMac up and down?
P
I have an old iMac probably early 2007 with a cd jammed in the slot. This has prevented me upgrading to Snow Leopard, which I require to be able to download any more recent OSX from the Mac Store or indeed use an AV nowadays.
I am wondering - if I buy a Snow Leopard CD from a store, can I use a Macbook Pro to place the content on a 8Gb stick and then transfer the whole thing onto the iMac and open and instal it there? I think it might be possible to use the MBP's Disk Utility to get it onto the stick.
I've tried all the recommendations for getting the CD out but they've all failed. Btw a YT video about removing stuck CDs unhelpfully spoke of inserting knives or steel rulers on the righthand side of the CD slot to avoid damaging the CD head. Of course on a iMac made after 2006 there is only top and bottom of the slit. I asked the techie who made the video which he meant by 'righthand'. He never replied. Can anyone say which is the safe end, top or bottom, for inserting a lever to 'unstick' a stuck cd.

Chowhound
Comic Vine
GameFAQs
GameSpot
Giant Bomb
TechRepublic