We had this problem in school sometimes (through no fault of our own, I might add)
It seems to do that when your keyboard randomly switches between US and UK keyboard layouts.
On a UK Keyboard, the @ appears on the same key as the apostrophe, whereas the " appears on the same key as the 2.